X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fsrc%2Fspam.c;h=5eff1ad5cb43b3c47241082786646767f55b4d8d;hb=4f10c76912b0ac78397ea157306460c20f30689a;hp=3ffc514f09cf13432f38beedc442929dfe9c3dcc;hpb=db3f7b6972f3b003c0413b78afcfbe295ffe0b97;p=user%2Fhenk%2Fcode%2Fexim.git diff --git a/src/src/spam.c b/src/src/spam.c index 3ffc514f0..5eff1ad5c 100644 --- a/src/src/spam.c +++ b/src/src/spam.c @@ -4,7 +4,7 @@ /* Copyright (c) Tom Kistner 2003 - 2015 * License: GPL - * Copyright (c) The Exim Maintainers 2016 - 2018 + * Copyright (c) The Exim Maintainers 2016 - 2020 */ /* Code for calling spamassassin's spamd. Called from acl.c. */ @@ -293,7 +293,7 @@ start = time(NULL); uschar * s; DEBUG(D_acl) debug_printf_indent("spamd: addr entry '%s'\n", address); - sd = (spamd_address_container *)store_get(sizeof(spamd_address_container)); + sd = store_get(sizeof(spamd_address_container), FALSE); for (sublist = address, args = 0, spamd_param_init(sd); (s = string_nextinlist(&sublist, &sublist_sep, NULL, 0)); @@ -344,7 +344,7 @@ start = time(NULL); for (;;) { /*XXX could potentially use TFO early-data here */ - if ( (spamd_cctx.sock = ip_streamsocket(sd->hostspec, &errstr, 5)) >= 0 + if ( (spamd_cctx.sock = ip_streamsocket(sd->hostspec, &errstr, 5, NULL)) >= 0 || sd->retry <= 0 ) break; @@ -503,7 +503,7 @@ offset = 0; while ((i = ip_recv(&spamd_cctx, spamd_buffer + offset, sizeof(spamd_buffer) - offset - 1, - sd->timeout - time(NULL) + start)) > 0) + sd->timeout + start)) > 0) offset += i; spamd_buffer[offset] = '\0'; /* guard byte */ @@ -565,7 +565,7 @@ else } Ustrcpy(spam_action_buffer, - spamd_score >= spamd_threshold ? "reject" : "no action"); + spamd_score >= spamd_threshold ? US"reject" : US"no action"); } /* Create report. Since this is a multiline string,