From d9b2c5e0d7da84499d359a9d5c1ebbb28572c5d6 Mon Sep 17 00:00:00 2001 From: phk Date: Thu, 24 Jul 2008 22:20:10 +0000 Subject: [PATCH] Relax an assert to only check what we really care about, and not the principle of the situation. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3020 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/lib/libvcl/vcc_acl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/varnish-cache/lib/libvcl/vcc_acl.c b/varnish-cache/lib/libvcl/vcc_acl.c index 442d29c9..09bc6f45 100644 --- a/varnish-cache/lib/libvcl/vcc_acl.c +++ b/varnish-cache/lib/libvcl/vcc_acl.c @@ -203,8 +203,8 @@ vcc_acl_try_getaddrinfo(struct tokenlist *tl, struct acl_e *ae) for(res = res0; res != NULL; res = res->ai_next) { switch(res->ai_family) { case PF_INET: + assert(PF_INET < 256); sin4 = (void*)res->ai_addr; - assert(sizeof(sin4->sin_family) == 1); assert(sizeof(sin4->sin_addr) == 4); u = (void*)&sin4->sin_addr; if (ae->t_mask == NULL) @@ -213,8 +213,8 @@ vcc_acl_try_getaddrinfo(struct tokenlist *tl, struct acl_e *ae) vcc_acl_emit_entry(tl, ae, 4, u, res->ai_family); break; case PF_INET6: + assert(PF_INET6 < 256); sin6 = (void*)res->ai_addr; - assert(sizeof(sin6->sin6_family) == 1); assert(sizeof(sin6->sin6_addr) == 16); u = (void*)&sin6->sin6_addr; if (ae->t_mask == NULL) -- 2.39.5