r3038 - trunk/varnish-cache/bin/varnishtest

phk at projects.linpro.no phk at projects.linpro.no
Thu Jul 31 11:52:27 CEST 2008


Author: phk
Date: 2008-07-31 11:52:27 +0200 (Thu, 31 Jul 2008)
New Revision: 3038

Modified:
   trunk/varnish-cache/bin/varnishtest/vtc_server.c
Log:
Accept ECONNRESET when closing sockets during cleanup.



Modified: trunk/varnish-cache/bin/varnishtest/vtc_server.c
===================================================================
--- trunk/varnish-cache/bin/varnishtest/vtc_server.c	2008-07-31 09:25:25 UTC (rev 3037)
+++ trunk/varnish-cache/bin/varnishtest/vtc_server.c	2008-07-31 09:52:27 UTC (rev 3038)
@@ -28,6 +28,7 @@
 
 
 #include <stdio.h>
+#include <errno.h>
 #include <stdlib.h>
 #include <unistd.h>
 #include <string.h>
@@ -97,7 +98,7 @@
 		http_process(vl, s->spec, fd, 0);
 		vtc_log(vl, 3, "shutting fd %d", fd);
 		AZ(shutdown(fd, SHUT_WR));
-		AZ(close(fd));
+		assert(close(fd) == 0 || errno == ECONNRESET);
 	}
 	vtc_log(vl, 2, "Ending");
 	return (NULL);




More information about the varnish-commit mailing list