diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-03-06 14:03:20 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-03-09 10:46:11 +0000 |
commit | a8f11faf7f584916078d6fadb36e0c2f1984e2b0 (patch) | |
tree | 1f7b00067a856148b01c4e017442297957da9b84 /src/libserver/protocol.c | |
parent | 3e3b94276f03f520bcd1756876c1077f250127d9 (diff) | |
download | rspamd-a8f11faf7f584916078d6fadb36e0c2f1984e2b0.tar.gz rspamd-a8f11faf7f584916078d6fadb36e0c2f1984e2b0.zip |
[Rework] Rework URL structure: adjust tld part
Diffstat (limited to 'src/libserver/protocol.c')
-rw-r--r-- | src/libserver/protocol.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libserver/protocol.c b/src/libserver/protocol.c index 16dc05491..739d3b950 100644 --- a/src/libserver/protocol.c +++ b/src/libserver/protocol.c @@ -878,11 +878,13 @@ rspamd_protocol_extended_url (struct rspamd_task *task, ucl_object_insert_key (obj, elt, "url", 0, false); if (url->tldlen > 0) { - elt = ucl_object_fromstring_common (url->tld, url->tldlen, 0); + elt = ucl_object_fromstring_common (rspamd_url_tld_unsafe (url), + url->tldlen, 0); ucl_object_insert_key (obj, elt, "tld", 0, false); } if (url->hostlen > 0) { - elt = ucl_object_fromstring_common (rspamd_url_host_unsafe (url), url->hostlen, 0); + elt = ucl_object_fromstring_common (rspamd_url_host_unsafe (url), + url->hostlen, 0); ucl_object_insert_key (obj, elt, "host", 0, false); } |