diff options
author | Peter Wu <peter@lekensteyn.nl> | 2017-02-27 10:52:08 +0100 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-02-27 12:52:36 +0000 |
commit | 220772dc19ef8b9c20a919375b47390a794c4e42 (patch) | |
tree | f02df344650a40d2d12ae38c627d28f8da8a568e /text2pcap.c | |
parent | 4b2a2eb0a4c393dcf29e505ed8f135e9b85fb60e (diff) |
text2pcap: fix -Wmacro-redefined warning
With flex 2.6.3, this warning is observed (which causes a build failure
when -Werror is not disabled:
text2pcap-scanner.c:398:9: warning: 'yywrap' macro redefined [-Wmacro-redefined]
#define yywrap() (/*CONSTCOND*/1)
^
text2pcap-scanner.c:76:13: note: previous definition is here
#define yywrap yywrap
Issue is specific to flex 2.6.3 and resolved upstream at
https://github.com/westes/flex/issues/162
Change-Id: I861565f5080f87a9457427e7a63b5d9256c49e85
Reviewed-on: https://code.wireshark.org/review/20294
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'text2pcap.c')
-rw-r--r-- | text2pcap.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/text2pcap.c b/text2pcap.c index 3ecc3511f9..851cb299b3 100644 --- a/text2pcap.c +++ b/text2pcap.c @@ -245,7 +245,7 @@ static FILE *output_file = NULL; /* Offset base to parse */ static guint32 offset_base = 16; -extern FILE *yyin; +extern FILE *text2pcap_in; /* ----- State machine -----------------------------------------------------------*/ @@ -1899,8 +1899,8 @@ main(int argc, char *argv[]) } curr_offset = header_length; - yyin = input_file; - if (yylex() == EXIT_SUCCESS) { + text2pcap_in = input_file; + if (text2pcap_lex() == EXIT_SUCCESS) { if (write_current_packet(FALSE) != EXIT_SUCCESS) ret = EXIT_FAILURE; } else { |