X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fsrc%2Fexpand.c;h=786d4279cbca4c667cc7eef0b03287c89a9a9f05;hb=faa05a9388f4efb82db4e7ea20ae746ab62f578a;hp=4dea8b12dba82fee08eea034ebb03482f652023d;hpb=ef21c07db8048e09fadab639d8946c9358d3d464;p=user%2Fhenk%2Fcode%2Fexim.git diff --git a/src/src/expand.c b/src/src/expand.c index 4dea8b12d..786d4279c 100644 --- a/src/src/expand.c +++ b/src/src/expand.c @@ -1869,6 +1869,7 @@ int i; uschar *tmp; int sav_narg = acl_narg; int ret; +extern int acl_where; if(--nsub > sizeof(acl_arg)/sizeof(*acl_arg)) nsub = sizeof(acl_arg)/sizeof(*acl_arg); for (i = 0; i < nsub && sub[i+1]; i++) @@ -1890,7 +1891,7 @@ DEBUG(D_expand) acl_narg>0 ? sub[1] : US"", acl_narg>1 ? " +more" : ""); -ret = acl_check(ACL_WHERE_EXPANSION, NULL, sub[0], user_msgp, &tmp); +ret = acl_eval(acl_where, NULL, sub[0], user_msgp, &tmp); for (i = 0; i < nsub; i++) acl_arg[i] = sub[i+1]; /* restore old args */ @@ -2147,14 +2148,13 @@ switch(cond_type) case ECOND_ACL: /* ${if acl {{name}{arg1}{arg2}...} {yes}{no}} */ { - uschar *nameargs; uschar *user_msg; BOOL cond = FALSE; int size = 0; int ptr = 0; while (isspace(*s)) s++; - if (*s++ != '{') goto COND_FAILED_CURLY_START; + if (*s++ != '{') goto COND_FAILED_CURLY_START; /*}*/ switch(read_subs(sub, sizeof(sub)/sizeof(*sub), 1, &s, yield == NULL, TRUE, US"acl")) @@ -5680,7 +5680,7 @@ while (*s != 0) uschar * list; int sep = 0; uschar * item; - uschar * suffix = ""; + uschar * suffix = US""; BOOL needsep = FALSE; uschar buffer[256]; @@ -5694,10 +5694,10 @@ while (*s != 0) } else switch(*arg) /* specific list-type version */ { - case 'a': t = tree_search(addresslist_anchor, sub); suffix = "_a"; break; - case 'd': t = tree_search(domainlist_anchor, sub); suffix = "_d"; break; - case 'h': t = tree_search(hostlist_anchor, sub); suffix = "_h"; break; - case 'l': t = tree_search(localpartlist_anchor, sub); suffix = "_l"; break; + case 'a': t = tree_search(addresslist_anchor, sub); suffix = US"_a"; break; + case 'd': t = tree_search(domainlist_anchor, sub); suffix = US"_d"; break; + case 'h': t = tree_search(hostlist_anchor, sub); suffix = US"_h"; break; + case 'l': t = tree_search(localpartlist_anchor, sub); suffix = US"_l"; break; default: expand_string_message = string_sprintf("bad suffix on \"list\" operator"); goto EXPAND_FAILED; @@ -5741,13 +5741,13 @@ while (*s != 0) if (*cp++ == ':') /* colon in a non-colon-sep list item, needs doubling */ { yield = string_cat(yield, &size, &ptr, US"::", 2); - item = cp; + item = (uschar *)cp; } else /* sep in item; should already be doubled; emit once */ { yield = string_cat(yield, &size, &ptr, (uschar *)tok, 1); if (*cp == sep) cp++; - item = cp; + item = (uschar *)cp; } } }