From: wessels <> Date: Tue, 23 Jul 1996 08:39:49 +0000 (+0000) Subject: break loop on lookup failures X-Git-Tag: SQUID_3_0_PRE1~6007 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8edf4af799756d13ad137395d690b2e2cc599d66;p=thirdparty%2Fsquid.git break loop on lookup failures --- diff --git a/src/acl.cc b/src/acl.cc index a0cd9d18ec..c25fcaad59 100644 --- a/src/acl.cc +++ b/src/acl.cc @@ -1,5 +1,5 @@ /* - * $Id: acl.cc,v 1.23 1996/07/22 17:19:12 wessels Exp $ + * $Id: acl.cc,v 1.24 1996/07/23 02:39:49 wessels Exp $ * * DEBUG: section 28 Access Control * AUTHOR: Duane Wessels @@ -680,6 +680,9 @@ int aclMatchAcl(acl, checklist) /* NOTREACHED */ case ACL_DST_IP: if ((hp = ipcache_gethostbyname(r->host, IP_LOOKUP_IF_MISS)) == NULL) { + /* if lookup previously failed, s_addr == INADDR_NONE */ + if (checklist->dst_addr.s_addr != INADDR_ANY) + return aclMatchIp(acl->data, checklist->dst_addr); debug(28, 3, "aclMatchAcl: Can't yet compare '%s' ACL for '%s'\n", acl->name, r->host); checklist->need |= (1 << ACL_DST_IP);