X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/32dfdf8baa8ccf091a0d5d4d75e8627424898756..9e70917d0aa5e51f584b2af69ce80df458ac5c79:/src/src/expand.c diff --git a/src/src/expand.c b/src/src/expand.c index d8d36a3b5..04bb92916 100644 --- a/src/src/expand.c +++ b/src/src/expand.c @@ -2377,8 +2377,10 @@ switch(cond_type) case 3: return NULL; } - *resetok = FALSE; /* eval_acl() might allocate; do not reclaim */ - if (yield != NULL) switch(eval_acl(sub, nelem(sub), &user_msg)) + if (yield != NULL) + { + *resetok = FALSE; /* eval_acl() might allocate; do not reclaim */ + switch(eval_acl(sub, nelem(sub), &user_msg)) { case OK: cond = TRUE; @@ -2399,6 +2401,7 @@ switch(cond_type) expand_string_message = string_sprintf("error from acl \"%s\"", sub[0]); return NULL; } + } return s; } @@ -6461,7 +6464,7 @@ while (*s != 0) blob b; char st[3]; - if (!exim_sha_init(&h, HASH_SHA256)) + if (!exim_sha_init(&h, HASH_SHA2_256)) { expand_string_message = US"unrecognised sha256 variant"; goto EXPAND_FAILED; @@ -6655,19 +6658,19 @@ while (*s != 0) char * cp; char tok[3]; tok[0] = sep; tok[1] = ':'; tok[2] = 0; - while ((cp= strpbrk((const char *)item, tok))) + while ((cp= strpbrk(CCS item, tok))) { - yield = string_catn(yield, &size, &ptr, item, cp-(char *)item); + yield = string_catn(yield, &size, &ptr, item, cp-CS item); if (*cp++ == ':') /* colon in a non-colon-sep list item, needs doubling */ { yield = string_catn(yield, &size, &ptr, US"::", 2); - item = (uschar *)cp; + item = US cp; } else /* sep in item; should already be doubled; emit once */ { - yield = string_catn(yield, &size, &ptr, (uschar *)tok, 1); + yield = string_catn(yield, &size, &ptr, US tok, 1); if (*cp == sep) cp++; - item = (uschar *)cp; + item = US cp; } } }