r1392 - trunk/varnish-cache/bin/varnishd

phk at projects.linpro.no phk at projects.linpro.no
Wed May 9 11:44:35 CEST 2007


Author: phk
Date: 2007-05-09 11:44:35 +0200 (Wed, 09 May 2007)
New Revision: 1392

Modified:
   trunk/varnish-cache/bin/varnishd/cache_vrt_acl.c
Log:
Don't use sockaddr->sa_len, it was too advanced for POSIX people.


Modified: trunk/varnish-cache/bin/varnishd/cache_vrt_acl.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/cache_vrt_acl.c	2007-05-09 08:44:28 UTC (rev 1391)
+++ trunk/varnish-cache/bin/varnishd/cache_vrt_acl.c	2007-05-09 09:44:35 UTC (rev 1392)
@@ -88,12 +88,10 @@
 	struct addrinfo *a1;
 	struct sockaddr_in *sin1, *sin2;
 
-	if (sa->sa_family == AF_INET) {
-		assert(sa->sa_len >= sizeof *sin1);
+	if (sa->sa_family == AF_INET)
 		sin1 = (void*)sa;
-	} else {
+	else
 		sin1 = NULL;
-	}
 
 	for ( ; ap->name != NULL; ap++) {
 		if (ap->priv == NULL && ap->paren)




More information about the varnish-commit mailing list