don't display "No packets captured" dialog, when using the new clear feature
authorulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7>
Tue, 12 Apr 2005 21:56:27 +0000 (21:56 +0000)
committerulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7>
Tue, 12 Apr 2005 21:56:27 +0000 (21:56 +0000)
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@14060 f5534014-38df-0310-8fa8-9805f1628bb7

capture.c

index 5b4df8b907ee272dfb2407b764386e2fc23d8ad5..200ddb452fc5d2e94a67e7583fc8c54848a04a6d 100644 (file)
--- a/capture.c
+++ b/capture.c
@@ -189,7 +189,7 @@ guint32 drops)
   }
 
   /* if we didn't captured even a single packet, close the file again */
-  if(cf_packet_count(capture_opts->cf) == 0) {
+  if(cf_packet_count(capture_opts->cf) == 0 && !capture_opts->restart) {
     simple_dialog(ESD_TYPE_INFO, ESD_BTN_OK, 
     "%sNo packets captured!%s\n\n"
     "As no data was captured, closing the %scapture file!",
@@ -305,7 +305,7 @@ capture_input_closed(capture_options *capture_opts)
         switch (cf_finish_tail(capture_opts->cf, &err)) {
 
         case CF_READ_OK:
-            if(cf_packet_count(capture_opts->cf) == 0) {
+            if(cf_packet_count(capture_opts->cf) == 0 && !capture_opts->restart) {
               simple_dialog(ESD_TYPE_INFO, ESD_BTN_OK, 
               "%sNo packets captured!%s\n\n"
               "As no data was captured, closing the %scapture file!",