diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-11-05 15:35:04 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-11-06 01:14:31 +0000 |
commit | ce2257899647c3980ad1493bdade0d81f2d2f17f (patch) | |
tree | 64503e90d80389f50f8333300e2a2b0089e7b6f1 | |
parent | d02104c9a61c353ce6ed54c6ca6207ed3a1fcdf0 (diff) |
Don't include io.h in Flex scanners - they're not interactive.
We don't have any Flex scanners that support an interactive command-line
interface, so none of our scanners are, or need to be, interactive.
Mark text2pcap's scanner as not interactive.
That means none of our scanners should call isatty(), so they don't have
any need to include <io.h> on Windows; remove that include from the
Lucent/Ascent text capture scanner.
Update a comment to reflect that what matters isn't whether we can read
from a terminal or whether we actually do so, what matters is whether
they read *interactively* from a terminal (if you want to run text2pcap
reading from the standard input and type at it, be my guest).
Change-Id: I59979d1fdb37e1913125a400963ff7a3fa6b9bbd
Reviewed-on: https://code.wireshark.org/review/11587
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
-rw-r--r-- | epan/dfilter/scanner.l | 2 | ||||
-rw-r--r-- | epan/diam_dict.l | 2 | ||||
-rw-r--r-- | epan/dtd_parse.l | 2 | ||||
-rw-r--r-- | epan/dtd_preparse.l | 2 | ||||
-rw-r--r-- | epan/radius_dict.l | 2 | ||||
-rw-r--r-- | epan/uat_load.l | 2 | ||||
-rw-r--r-- | plugins/mate/mate_parser.l | 2 | ||||
-rw-r--r-- | plugins/wimaxasncp/wimaxasncp_dict.l | 2 | ||||
-rw-r--r-- | text2pcap-scanner.l | 5 | ||||
-rw-r--r-- | ui/text_import_scanner.l | 2 | ||||
-rw-r--r-- | wiretap/ascend_scanner.l | 6 | ||||
-rw-r--r-- | wiretap/k12text.l | 2 |
12 files changed, 16 insertions, 15 deletions
diff --git a/epan/dfilter/scanner.l b/epan/dfilter/scanner.l index eedee62b07..be45f7390c 100644 --- a/epan/dfilter/scanner.l +++ b/epan/dfilter/scanner.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/epan/diam_dict.l b/epan/diam_dict.l index 514cd8d1d2..9a9bdacf36 100644 --- a/epan/diam_dict.l +++ b/epan/diam_dict.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/epan/dtd_parse.l b/epan/dtd_parse.l index 551823ddda..14e3b04e99 100644 --- a/epan/dtd_parse.l +++ b/epan/dtd_parse.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/epan/dtd_preparse.l b/epan/dtd_preparse.l index 76f1e86117..306e5d8f5a 100644 --- a/epan/dtd_preparse.l +++ b/epan/dtd_preparse.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/epan/radius_dict.l b/epan/radius_dict.l index 25f313afb3..c043856626 100644 --- a/epan/radius_dict.l +++ b/epan/radius_dict.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/epan/uat_load.l b/epan/uat_load.l index ae5287a006..5c634f56aa 100644 --- a/epan/uat_load.l +++ b/epan/uat_load.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/plugins/mate/mate_parser.l b/plugins/mate/mate_parser.l index 45f50c8c63..855637aebf 100644 --- a/plugins/mate/mate_parser.l +++ b/plugins/mate/mate_parser.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/plugins/wimaxasncp/wimaxasncp_dict.l b/plugins/wimaxasncp/wimaxasncp_dict.l index ee8a2b4bfc..47547d493d 100644 --- a/plugins/wimaxasncp/wimaxasncp_dict.l +++ b/plugins/wimaxasncp/wimaxasncp_dict.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/text2pcap-scanner.l b/text2pcap-scanner.l index a860df66a0..0f264f6d1e 100644 --- a/text2pcap-scanner.l +++ b/text2pcap-scanner.l @@ -10,6 +10,11 @@ */ %option nounput +/* + * We don't read interactively from the terminal. + */ +%option never-interactive + %{ /******************************************************************************** diff --git a/ui/text_import_scanner.l b/ui/text_import_scanner.l index 026ab24c7c..625cc050d1 100644 --- a/ui/text_import_scanner.l +++ b/ui/text_import_scanner.l @@ -6,7 +6,7 @@ %option nounput noinput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive diff --git a/wiretap/ascend_scanner.l b/wiretap/ascend_scanner.l index cae8d40eda..402ce26063 100644 --- a/wiretap/ascend_scanner.l +++ b/wiretap/ascend_scanner.l @@ -1,5 +1,5 @@ /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive @@ -36,10 +36,6 @@ #include <stdlib.h> #include <string.h> -#ifdef HAVE_IO_H -#include <io.h> /* for isatty() on win32 */ -#endif - #include "wtap-int.h" #include "ascendtext.h" #include "ascend.h" diff --git a/wiretap/k12text.l b/wiretap/k12text.l index c35b396007..350393538a 100644 --- a/wiretap/k12text.l +++ b/wiretap/k12text.l @@ -9,7 +9,7 @@ %option nounput /* - * We don't read from the terminal. + * We don't read interactively from the terminal. */ %option never-interactive |