From: Vsevolod Stakhov Date: Wed, 22 Apr 2015 16:43:12 +0000 (+0100) Subject: Fix TLD sanity checking. X-Git-Tag: 0.9.0~171 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=36121e8e867c257fbffa7be515e8a2af43a2246e;p=thirdparty%2Frspamd.git Fix TLD sanity checking. --- diff --git a/src/libserver/url.c b/src/libserver/url.c index 43ef9f9b1d..9e0fed1107 100644 --- a/src/libserver/url.c +++ b/src/libserver/url.c @@ -1475,8 +1475,8 @@ rspamd_url_trie_callback (int strnum, int textpos, void *context) } if (matcher->flags & URL_FLAG_TLD_MATCH) { - /* Immediately check pos + 1 for valid chars */ - pos = &cb->begin[textpos + 1]; + /* Immediately check pos for valid chars */ + pos = &cb->begin[textpos]; if (pos < cb->end) { if (!g_ascii_isspace (*pos) && *pos != '/' && *pos != '?' && *pos != ':') { return 0;