diff options
author | Guy Harris <guy@alum.mit.edu> | 1999-11-25 22:37:53 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 1999-11-25 22:37:53 +0000 |
commit | 298f3b240290361a76a63201b3ecf28d60d3fa88 (patch) | |
tree | 9b99ac4d6bd656dc9e7ede6282e47b2cf3c2ee37 /capture.c | |
parent | 2a696fc41ae3eb7dbb379b6fa10548779ff45a88 (diff) | |
download | wireshark-298f3b240290361a76a63201b3ecf28d60d3fa88.tar.gz wireshark-298f3b240290361a76a63201b3ecf28d60d3fa88.tar.bz2 wireshark-298f3b240290361a76a63201b3ecf28d60d3fa88.zip |
On a "wtap_dump_close()" error, if it's not one of the errors for which
we put up a special error, just use "wtap_strerror()" to generate the
error message - it'll handle both "errno" errors and Wiretap-specific
errors.
svn path=/trunk/; revision=1108
Diffstat (limited to 'capture.c')
-rw-r--r-- | capture.c | 13 |
1 files changed, 3 insertions, 10 deletions
@@ -1,7 +1,7 @@ /* capture.c * Routines for packet capture windows * - * $Id: capture.c,v 1.80 1999/10/20 22:35:57 gram Exp $ + * $Id: capture.c,v 1.81 1999/11/25 22:37:53 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -506,17 +506,10 @@ capture(void) break; default: - if (err < 0) { - simple_dialog(ESD_TYPE_WARN, NULL, - "The file to which the capture was being" - " saved (\"%s\") could not be closed: Error %d.", - cf.save_file, err); - } else { - simple_dialog(ESD_TYPE_WARN, NULL, + simple_dialog(ESD_TYPE_WARN, NULL, "The file to which the capture was being" " saved (\"%s\") could not be closed: %s.", - cf.save_file, strerror(err)); - } + cf.save_file, wtap_strerror(err)); break; } } |