Include <string.h> and <ctype.h> to get the appropriate functions
authorguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Thu, 24 Feb 2005 05:39:59 +0000 (05:39 +0000)
committerguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Thu, 24 Feb 2005 05:39:59 +0000 (05:39 +0000)
declared and macros defined.

Pass all the necessary arguments to "get_natural_int()".

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@13490 f5534014-38df-0310-8fa8-9805f1628bb7

capture_opts.c

index 4a27d7e89228e27e53f7934327823358de1b4dbc..5b384aa34e5c51c9f0bd15c460968b7f2f23dbce 100644 (file)
@@ -28,6 +28,9 @@
 
 #ifdef HAVE_LIBPCAP
 
+#include <string.h>
+#include <ctype.h>
+
 #ifdef HAVE_IO_H
 # include <io.h>
 #endif
@@ -297,7 +300,7 @@ capture_opts_add_opt(capture_options *capture_opts, const char *appname, int opt
         }
 #else /* HAVE_PCAP_DATALINK_NAME_TO_VAL */
         /* XXX - just treat it as a number */
-        capture_opts->linktype = get_natural_int(optarg, "data link type");
+        capture_opts->linktype = get_natural_int(appname, optarg, "data link type");
 #endif /* HAVE_PCAP_DATALINK_NAME_TO_VAL */
         break;
 #ifdef _WIN32
@@ -317,4 +320,4 @@ capture_opts_add_opt(capture_options *capture_opts, const char *appname, int opt
     }
 }
 
-#endif /* HAVE_LIBPCAP */
\ No newline at end of file
+#endif /* HAVE_LIBPCAP */