From b46c52d65c18534ef865ae54cbce66f559fa9468 Mon Sep 17 00:00:00 2001 From: Johan Wikman Date: Tue, 27 Feb 2018 18:50:18 +0200 Subject: [PATCH] MXS-1684 Match space+linefeed as linefeed A linefeed is whitespace, so given the rules "\n"+ return '\n' {SPACE} ; a line consisting of space followed by a linefeed, will be matched as space and not as a linefeed and hence will cause the parser to barf. --- server/modules/filter/dbfwfilter/token.l | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/modules/filter/dbfwfilter/token.l b/server/modules/filter/dbfwfilter/token.l index 324e2cbf5..c27c02c76 100644 --- a/server/modules/filter/dbfwfilter/token.l +++ b/server/modules/filter/dbfwfilter/token.l @@ -36,7 +36,7 @@ USTR [%-_[:alnum:][:punct:]]+ CMP [=<>!]+ %% -"\n"+ return '\n'; +{SPACE}"\n"+ return '\n'; {COMMENT} return FWTOK_COMMENT; deny|allow return FWTOK_DENY; /** This should be removed at some point */ rule return FWTOK_RULE;