settings: Merge quoted strings that span multiple lines
authorTobias Brunner <tobias@strongswan.org>
Thu, 19 Mar 2015 17:34:02 +0000 (18:34 +0100)
committerTobias Brunner <tobias@strongswan.org>
Fri, 20 Mar 2015 17:37:22 +0000 (18:37 +0100)
src/libstrongswan/settings/settings_lexer.l

index c6546f4..176387f 100644 (file)
@@ -148,9 +148,8 @@ static void include_files(parser_helper_t *ctx);
        \\t     yyextra->string_add(yyextra, "\t");
        \\b     yyextra->string_add(yyextra, "\b");
        \\f     yyextra->string_add(yyextra, "\f");
-       \\(.|\n)                        {
-               yyextra->string_add(yyextra, yytext+1);
-       }
+       \\\r?\n /* merge lines that end with EOL characters */
+       \\.     yyextra->string_add(yyextra, yytext+1);
        [^\\\n"]+                       {
                yyextra->string_add(yyextra, yytext);
        }