diff options
author | Guy Harris <guy@alum.mit.edu> | 2001-12-21 20:18:40 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2001-12-21 20:18:40 +0000 |
commit | b89a117a611d9bc34501e2fdccc9aa7fc7d87ea5 (patch) | |
tree | 428a650c025e919c7f4c891544946cba938907c4 /gtk | |
parent | 393fba6ff29aabd5f0d1473c96da9db08beb6f7f (diff) | |
download | wireshark-b89a117a611d9bc34501e2fdccc9aa7fc7d87ea5.tar.gz wireshark-b89a117a611d9bc34501e2fdccc9aa7fc7d87ea5.tar.bz2 wireshark-b89a117a611d9bc34501e2fdccc9aa7fc7d87ea5.zip |
There is no such thing as an optional parameter to a command-line flag
if you're using "getopt" - if a flag requires a parameter, not
specifying the parameter is an error.
svn path=/trunk/; revision=4437
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/main.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/gtk/main.c b/gtk/main.c index ad3d32ba8c..d9b9f35aba 100644 --- a/gtk/main.c +++ b/gtk/main.c @@ -1,6 +1,6 @@ /* main.c * - * $Id: main.c,v 1.219 2001/12/18 19:09:08 gram Exp $ + * $Id: main.c,v 1.220 2001/12/21 20:18:40 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -1136,13 +1136,7 @@ main(int argc, char *argv[]) case 'b': /* Ringbuffer option */ #ifdef HAVE_LIBPCAP cfile.ringbuffer_on = TRUE; - /* get optional ringbuffer number of files parameter */ - if (optarg[0] != '-') { - cfile.ringbuffer_num_files = get_positive_int(optarg, "ringbuffer number of files"); - } else { - cfile.ringbuffer_num_files = RINGBUFFER_MIN_NUM_FILES; - optind--; - } + cfile.ringbuffer_num_files = get_positive_int(optarg, "number of ring buffer files"); #else capture_option_specified = TRUE; arg_error = TRUE; |