From 0eb055f6163508bcd0c80546bce1e92e9d4e3817 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Tue, 27 Jul 2021 20:15:04 +0100 Subject: [PATCH] [Minor] Fix overflow tags parsing --- src/libserver/html/html.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libserver/html/html.cxx b/src/libserver/html/html.cxx index ab49d147b..9c96f2bb9 100644 --- a/src/libserver/html/html.cxx +++ b/src/libserver/html/html.cxx @@ -1875,7 +1875,7 @@ html_process_input(rspamd_mempool_t *pool, msg_warn_pool("tags limit of %d tags is reached at the position %d;" " ignoring the rest of the HTML content", (int) hc->all_tags.size(), (int) (p - start)); - html_append_parsed(hc, {p, (std::size_t) (end - p)}, false); + c = p; p = end; break; } @@ -1957,6 +1957,9 @@ html_process_input(rspamd_mempool_t *pool, process_opening_tag(); } break; + case tags_limit_overflow: + html_append_parsed(hc, {c, (std::size_t) (end - c)}, false); + break; default: /* Do nothing */ break; -- 2.39.5