diff --git a/tshark.c b/tshark.c index 0db7cb4cd8..0a840d0fb9 100644 --- a/tshark.c +++ b/tshark.c @@ -1794,9 +1794,10 @@ main(int argc, char *argv[]) } if (!global_capture_opts.has_autostop_filesize && !global_capture_opts.has_file_duration && - !global_capture_opts.has_file_interval) { + !global_capture_opts.has_file_interval && + !global_capture_opts.has_file_packets) { cmdarg_err("Multiple capture files requested, but " - "no maximum capture file size, duration or interval was specified."); + "no maximum capture file size, duration, interval or packets were specified."); exit_status = INVALID_OPTION; goto clean_exit; } diff --git a/ui/commandline.c b/ui/commandline.c index e14daa58b9..9d114182a6 100644 --- a/ui/commandline.c +++ b/ui/commandline.c @@ -670,8 +670,9 @@ void commandline_other_options(int argc, char *argv[], gboolean opt_reset) } if (!global_capture_opts.has_autostop_filesize && !global_capture_opts.has_file_duration && - !global_capture_opts.has_file_interval) { - cmdarg_err("Ring buffer requested, but no maximum capture file size, duration or interval were specified."); + !global_capture_opts.has_file_interval && + !global_capture_opts.has_file_packets) { + cmdarg_err("Ring buffer requested, but no maximum capture file size, duration, interval or packets were specified."); /* XXX - this must be redesigned as the conditions changed */ } }