git://git.exim.org
/
exim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
typo
[exim.git]
/
src
/
src
/
lookups
/
readsock.c
diff --git
a/src/src/lookups/readsock.c
b/src/src/lookups/readsock.c
index cfc9b4ad82b5a62e65d21d01d6c41d0c446f304d..f7e04d1d86b83c1c504df5b5bb6e000b42943dbb 100644
(file)
--- a/
src/src/lookups/readsock.c
+++ b/
src/src/lookups/readsock.c
@@
-13,8
+13,6
@@
static int
internal_readsock_open(client_conn_ctx * cctx, const uschar * sspec,
int timeout, BOOL do_tls, uschar ** errmsg)
{
internal_readsock_open(client_conn_ctx * cctx, const uschar * sspec,
int timeout, BOOL do_tls, uschar ** errmsg)
{
-int sep = ',';
-uschar * ele;
const uschar * server_name;
host_item host;
const uschar * server_name;
host_item host;
@@
-182,7
+180,6
@@
struct {
} lf = {.do_shutdown = TRUE};
uschar * eol = NULL;
int timeout = 5;
} lf = {.do_shutdown = TRUE};
uschar * eol = NULL;
int timeout = 5;
-FILE * fp;
gstring * yield;
int ret = DEFER;
gstring * yield;
int ret = DEFER;
@@
-250,16
+247,23
@@
that reads a file can be used. If we're using a stdio buffered read,
and might need later write ops on the socket, the stdio must be in
writable mode or the underlying socket goes non-writable. */
and might need later write ops on the socket, the stdio must be in
writable mode or the underlying socket goes non-writable. */
-if (!cctx->tls_ctx)
- fp = fdopen(cctx->sock, lf.do_shutdown ? "rb" : "wb");
-
sigalrm_seen = FALSE;
sigalrm_seen = FALSE;
-ALARM(timeout);
-yield =
-#
ifndef DISABLE_TLS
- cctx->tls_ctx ? cat_file_tls(cctx->tls_ctx, NULL, eol) :
+#ifdef DISABLE_TLS
+if (TRUE)
+#
else
+if (!cctx->tls_ctx)
#endif
#endif
- cat_file(fp, NULL, eol);
+ {
+ FILE * fp = fdopen(cctx->sock, lf.do_shutdown ? "rb" : "wb");
+ ALARM(timeout);
+ yield = cat_file(fp, NULL, eol);
+ }
+else
+ {
+ ALARM(timeout);
+ yield = cat_file_tls(cctx->tls_ctx, NULL, eol);
+ }
+
ALARM_CLR(0);
if (sigalrm_seen)
ALARM_CLR(0);
if (sigalrm_seen)