]> source.dussan.org Git - rspamd.git/commitdiff
Use tld for redirector's matching.
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 25 Jun 2015 14:42:16 +0000 (15:42 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 25 Jun 2015 14:42:16 +0000 (15:42 +0100)
src/plugins/surbl.c

index 428e2902ec5e855e7b1ff5bd005c77be47b41773..9e38dade7473227e69de8b21af07580f2454eaed 100644 (file)
@@ -1081,8 +1081,8 @@ surbl_tree_url_callback (gpointer key, gpointer value, void *data)
        if (surbl_module_ctx->use_redirector) {
                /* Search in trie */
                if (surbl_module_ctx->redirector_trie) {
-                       idx = acism_lookup (surbl_module_ctx->redirector_trie, url->host,
-                                       url->hostlen, surbl_redirector_trie_cb, url, &state, true);
+                       idx = acism_lookup (surbl_module_ctx->redirector_trie, url->tld,
+                                       url->tldlen, surbl_redirector_trie_cb, url, &state, true);
                        if (idx > 0) {
                                pat = &g_array_index (surbl_module_ctx->redirector_ptrs,
                                                ac_trie_pat_t, idx - 1);