Allow #include within a :text block
Showing
1 changed file
with
2 additions
and
1 deletions
... | @@ -350,6 +350,7 @@ text: { BEGIN(ML); multiline_begin (); } | ... | @@ -350,6 +350,7 @@ text: { BEGIN(ML); multiline_begin (); } |
350 | multiline_add (); | 350 | multiline_add (); |
351 | multiline_finish (); | 351 | multiline_finish (); |
352 | return MULTILINE; } | 352 | return MULTILINE; } |
353 | <ML>#[ \t]*include.*\n { sieve_include (); } | ||
353 | <ML>.*\n { sieve_line_num++; multiline_add (); } | 354 | <ML>.*\n { sieve_line_num++; multiline_add (); } |
354 | {WS} ; | 355 | {WS} ; |
355 | \n { sieve_line_num++; } | 356 | \n { sieve_line_num++; } |
... | @@ -439,7 +440,7 @@ sieve_include () | ... | @@ -439,7 +440,7 @@ sieve_include () |
439 | if (usepath && name[0] != '/' && memcmp (name, "..", 2)) | 440 | if (usepath && name[0] != '/' && memcmp (name, "..", 2)) |
440 | { | 441 | { |
441 | char *p = name; | 442 | char *p = name; |
442 | if (list_do (sieve_include_path, _try_include, &p)) | 443 | if (sieve_include_path && list_do (sieve_include_path, _try_include, &p)) |
443 | { | 444 | { |
444 | push_source (p); | 445 | push_source (p); |
445 | free (name); | 446 | free (name); | ... | ... |
-
Please register or sign in to post a comment