diff options
Diffstat (limited to 'src/libserver/html.c')
-rw-r--r-- | src/libserver/html.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libserver/html.c b/src/libserver/html.c index 175398aa3..00b4e24a5 100644 --- a/src/libserver/html.c +++ b/src/libserver/html.c @@ -848,8 +848,9 @@ rspamd_html_url_is_phished (rspamd_mempool_t *pool, url_text ++; } - if (rspamd_url_find (pool, url_text, end - url_text, &url_str, FALSE, - &url_pos) && + if (end > url_text + 4 && + rspamd_url_find (pool, url_text, end - url_text, &url_str, FALSE, + &url_pos) && url_str != NULL) { if (url_pos > 0) { /* |