diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-03-26 15:41:04 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-03-26 15:41:04 +0000 |
commit | ab4950c5eac19bd5d5aeac2a1c4772e9fd893f37 (patch) | |
tree | 23f5d8fa67821be47be7e0f0ab7391795e66bb65 /contrib/libucl/ucl_parser.c | |
parent | 3bf124702cfd42962e321791ba0849c4a5799ecd (diff) | |
download | rspamd-ab4950c5eac19bd5d5aeac2a1c4772e9fd893f37.tar.gz rspamd-ab4950c5eac19bd5d5aeac2a1c4772e9fd893f37.zip |
[Minor] Allow unconditional special handlers
Diffstat (limited to 'contrib/libucl/ucl_parser.c')
-rw-r--r-- | contrib/libucl/ucl_parser.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/contrib/libucl/ucl_parser.c b/contrib/libucl/ucl_parser.c index 574e240ab..59bfd7727 100644 --- a/contrib/libucl/ucl_parser.c +++ b/contrib/libucl/ucl_parser.c @@ -2862,8 +2862,9 @@ ucl_parser_add_chunk_full (struct ucl_parser *parser, const unsigned char *data, memset (chunk, 0, sizeof (*chunk)); LL_FOREACH (parser->special_handlers, special_handler) { - if (len >= special_handler->magic_len && - memcmp (data, special_handler->magic, special_handler->magic_len) == 0) { + if ((special_handler->flags & UCL_SPECIAL_HANDLER_PREPROCESS_ALL) || + (len >= special_handler->magic_len && + memcmp (data, special_handler->magic, special_handler->magic_len) == 0)) { unsigned char *ndata = NULL; size_t nlen = 0; |