diff options
author | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 2001-11-24 02:13:34 +0000 |
---|---|---|
committer | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 2001-11-24 02:13:34 +0000 |
commit | aa040ae75864d998b7e580404e63b4181f9b594d (patch) | |
tree | a5b2242392782454674a36fc6193de0eac95b26a /text2pcap-scanner.l | |
parent | 429b2da06af4102cf9fb708fdbc48bf05e171c17 (diff) |
Treat a bunch of digits followed by a newline differently from a bunch
of digits followed by a blank or tab, so that we recognize the newline
as an end-of-line.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@4249 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'text2pcap-scanner.l')
-rw-r--r-- | text2pcap-scanner.l | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/text2pcap-scanner.l b/text2pcap-scanner.l index 63835a1e39..954c8dfae0 100644 --- a/text2pcap-scanner.l +++ b/text2pcap-scanner.l @@ -10,7 +10,7 @@ * * (c) Copyright 2001 Ashok Narayanan <ashokn@cisco.com> * - * $Id: text2pcap-scanner.l,v 1.1 2001/05/16 21:32:04 ashokn Exp $ + * $Id: text2pcap-scanner.l,v 1.2 2001/11/24 02:13:34 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -46,7 +46,8 @@ directive #TEXT2PCAP.* comment #[^W].* byte [0-9A-Fa-f][0-9A-Fa-f][ \t] byte_eol [0-9A-Fa-f][0-9A-Fa-f]\n -offset [0-9A-Fa-f]+[ \t\n] +offset [0-9A-Fa-f]+[ \t] +offset_eol [0-9A-Fa-f]+\n text [^ \n\t]+ mailfwd > eol \r?\n\r? @@ -56,6 +57,7 @@ eol \r?\n\r? {byte} { parse_token(T_BYTE, yytext); } {byte_eol} { parse_token(T_BYTE, yytext); parse_token(T_EOL, NULL); } {offset} { parse_token(T_OFFSET, yytext); } +{offset_eol} { parse_token(T_OFFSET, yytext); parse_token(T_EOL, NULL); } {mailfwd}{offset} { parse_token(T_OFFSET, yytext+1); } {eol} { parse_token(T_EOL, NULL); } [ \t] ; /* ignore whitespace */ |