diff options
author | Guy Harris <guy@alum.mit.edu> | 2010-06-16 01:30:29 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2010-06-16 01:30:29 +0000 |
commit | d4cc16d4a18b0b012d0284f49b381cc88a9e8de9 (patch) | |
tree | ddf069b22dcc6d8120c4f8aa5fac6b536cb4cca3 /epan/filesystem.c | |
parent | b940189f7afcd9debc3381e63c11f9af2be52dab (diff) |
Handle WTAP_ERR_SHORT_WRITE in file_write_error_message().
In eo_save_entry(), don't assume you can write the entire object in a
single write call - if the object is big enough (which would require a
64-bit address space), and you're not lucky enough to be running on
UN*X (which means LP64, so size_t and ssize_t are big enough for the
entire object), you can't.
svn path=/trunk/; revision=33231
Diffstat (limited to 'epan/filesystem.c')
-rw-r--r-- | epan/filesystem.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/epan/filesystem.c b/epan/filesystem.c index 98468b1619..77306bd728 100644 --- a/epan/filesystem.c +++ b/epan/filesystem.c @@ -1665,6 +1665,10 @@ file_write_error_message(int err) break; #endif + case WTAP_ERR_SHORT_WRITE: + errmsg = "A full write couldn't be done to the file \"%s\"."; + break; + default: g_snprintf(errmsg_errno, sizeof(errmsg_errno), "An error occurred while writing to the file \"%%s\": %s.", |