X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/ae8f9024d8d4fad31457d758022e3186d782929c..b536a578fbabdc9d39da53d54a8d7700ba537431:/src/src/expand.c diff --git a/src/src/expand.c b/src/src/expand.c index ca7d36838..49e09ecd8 100644 --- a/src/src/expand.c +++ b/src/src/expand.c @@ -1687,7 +1687,7 @@ else return g; if (sender_host_address) - g = string_append(g, 2, US" smtp.client-ip=", sender_host_address); + g = string_append(g, 2, US" smtp.remote-ip=", sender_host_address); return g; } @@ -5021,6 +5021,7 @@ while (*s != 0) port = ntohs(service_info->s_port); } + /*XXX we trust that the request is idempotent. Hmm. */ fd = ip_connectedsocket(SOCK_STREAM, server_name, port, port, timeout, &host, &expand_string_message, do_tls ? NULL : &reqstr); @@ -5051,9 +5052,9 @@ while (*s != 0) server_name = US sockun.sun_path; sigalrm_seen = FALSE; - alarm(timeout); + ALARM(timeout); rc = connect(fd, (struct sockaddr *)(&sockun), sizeof(sockun)); - alarm(0); + ALARM_CLR(0); if (sigalrm_seen) { expand_string_message = US "socket connect timed out"; @@ -5126,13 +5127,13 @@ while (*s != 0) if (!tls_ctx) fp = fdopen(fd, "rb"); sigalrm_seen = FALSE; - alarm(timeout); + ALARM(timeout); yield = #ifdef SUPPORT_TLS tls_ctx ? cat_file_tls(tls_ctx, yield, sub_arg[3]) : #endif cat_file(fp, yield, sub_arg[3]); - alarm(0); + ALARM_CLR(0); #ifdef SUPPORT_TLS if (tls_ctx) @@ -5265,9 +5266,9 @@ while (*s != 0) resetok = FALSE; f = fdopen(fd_out, "rb"); sigalrm_seen = FALSE; - alarm(60); + ALARM(60); lookup_value = string_from_gstring(cat_file(f, NULL, NULL)); - alarm(0); + ALARM_CLR(0); (void)fclose(f); /* Wait for the process to finish, applying the timeout, and inspect its @@ -5811,7 +5812,7 @@ while (*s != 0) } if (Ustrcmp(item, sub[0]) == 0) /*XXX should be a UTF8-compare */ { - s = item + strlen(item) + 1; + s = item + Ustrlen(item) + 1; while (isspace(*s)) s++; if (*s != ':') {