[master] 069341b84 Merge from VTEST

Poul-Henning Kamp phk at FreeBSD.org
Mon May 6 19:04:12 UTC 2019


commit 069341b84f2d3dcc1c710183ca0850bbe4a71662
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Mon May 6 19:03:18 2019 +0000

    Merge from VTEST

diff --git a/bin/varnishtest/vtc_syslog.c b/bin/varnishtest/vtc_syslog.c
index b9862eb50..d4f7dbc15 100644
--- a/bin/varnishtest/vtc_syslog.c
+++ b/bin/varnishtest/vtc_syslog.c
@@ -151,7 +151,10 @@ VUDP_close(int *s)
 static int
 VUDP_bind(const struct suckaddr *sa, const char **errp)
 {
-	int sd, val, e;
+#ifdef IPV6_V6ONLY
+	int val;
+#endif
+	int sd, e;
 	socklen_t sl;
 	const struct sockaddr *so;
 	int proto;
@@ -166,15 +169,6 @@ VUDP_bind(const struct suckaddr *sa, const char **errp)
 			*errp = "socket(2)";
 		return (-1);
 	}
-	val = 1;
-	if (setsockopt(sd, SOL_SOCKET, SO_REUSEADDR, &val, sizeof val) != 0) {
-		if (errp != NULL)
-			*errp = "setsockopt(SO_REUSEADDR, 1)";
-		e = errno;
-		closefd(&sd);
-		errno = e;
-		return (-1);
-	}
 
 #ifdef IPV6_V6ONLY
 	/* forcibly use separate sockets for IPv4 and IPv6 */


More information about the varnish-commit mailing list