dovecot-2.2: lib-dns: Fixed handling write() failure to dns-look...

dovecot at dovecot.org dovecot at dovecot.org
Fri Nov 22 23:15:22 EET 2013


details:   http://hg.dovecot.org/dovecot-2.2/rev/75b6c3b8ee20
changeset: 17006:75b6c3b8ee20
user:      Timo Sirainen <tss at iki.fi>
date:      Fri Nov 22 23:15:07 2013 +0200
description:
lib-dns: Fixed handling write() failure to dns-lookup server process.

diffstat:

 src/lib-dns/dns-lookup.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (16 lines):

diff -r d2f2423615d7 -r 75b6c3b8ee20 src/lib-dns/dns-lookup.c
--- a/src/lib-dns/dns-lookup.c	Fri Nov 22 22:12:08 2013 +0200
+++ b/src/lib-dns/dns-lookup.c	Fri Nov 22 23:15:07 2013 +0200
@@ -319,8 +319,10 @@
 		return -1;
 	}
 	if (write_full(client->fd, cmd, strlen(cmd)) < 0) {
-		dns_client_disconnect(client, t_strdup_printf(
-			"write(%s) failed: %m", client->path));
+		result.error = t_strdup_printf("write(%s) failed: %m",
+					       client->path);
+		dns_client_disconnect(client, result.error);
+		callback(&result, context);
 		return -1;
 	}
 


More information about the dovecot-cvs mailing list