mirror of
https://github.com/zeek/zeek.git
synced 2025-10-03 15:18:20 +00:00
reorder a few statements in scan.l to make 1.5msecs etc work.
Adresses #872
This commit is contained in:
parent
7e3f06fca3
commit
f6c9b69eda
1 changed files with 6 additions and 6 deletions
12
src/scan.l
12
src/scan.l
|
@ -479,12 +479,6 @@ F RET_CONST(new Val(false, TYPE_BOOL))
|
||||||
RET_CONST(new PortVal(p, TRANSPORT_UNKNOWN))
|
RET_CONST(new PortVal(p, TRANSPORT_UNKNOWN))
|
||||||
}
|
}
|
||||||
|
|
||||||
({D}"."){3}{D} RET_CONST(new AddrVal(yytext))
|
|
||||||
|
|
||||||
"0x"{HEX}+ RET_CONST(new Val(static_cast<bro_uint_t>(strtoull(yytext, 0, 16)), TYPE_COUNT))
|
|
||||||
|
|
||||||
{H}("."{H})+ RET_CONST(dns_mgr->LookupHost(yytext))
|
|
||||||
|
|
||||||
{FLOAT}{OWS}day(s?) RET_CONST(new IntervalVal(atof(yytext),Days))
|
{FLOAT}{OWS}day(s?) RET_CONST(new IntervalVal(atof(yytext),Days))
|
||||||
{FLOAT}{OWS}hr(s?) RET_CONST(new IntervalVal(atof(yytext),Hours))
|
{FLOAT}{OWS}hr(s?) RET_CONST(new IntervalVal(atof(yytext),Hours))
|
||||||
{FLOAT}{OWS}min(s?) RET_CONST(new IntervalVal(atof(yytext),Minutes))
|
{FLOAT}{OWS}min(s?) RET_CONST(new IntervalVal(atof(yytext),Minutes))
|
||||||
|
@ -492,6 +486,12 @@ F RET_CONST(new Val(false, TYPE_BOOL))
|
||||||
{FLOAT}{OWS}msec(s?) RET_CONST(new IntervalVal(atof(yytext),Milliseconds))
|
{FLOAT}{OWS}msec(s?) RET_CONST(new IntervalVal(atof(yytext),Milliseconds))
|
||||||
{FLOAT}{OWS}usec(s?) RET_CONST(new IntervalVal(atof(yytext),Microseconds))
|
{FLOAT}{OWS}usec(s?) RET_CONST(new IntervalVal(atof(yytext),Microseconds))
|
||||||
|
|
||||||
|
({D}"."){3}{D} RET_CONST(new AddrVal(yytext))
|
||||||
|
|
||||||
|
"0x"{HEX}+ RET_CONST(new Val(static_cast<bro_uint_t>(strtoull(yytext, 0, 16)), TYPE_COUNT))
|
||||||
|
|
||||||
|
{H}("."{H})+ RET_CONST(dns_mgr->LookupHost(yytext))
|
||||||
|
|
||||||
\"([^\\\n\"]|{ESCSEQ})*\" {
|
\"([^\\\n\"]|{ESCSEQ})*\" {
|
||||||
const char* text = yytext;
|
const char* text = yytext;
|
||||||
int len = strlen(text) + 1;
|
int len = strlen(text) + 1;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue