]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Bug 3239: Rename myip/myport as localip/localport - Fix initial patch
authorChristos Tsantilas <chtsanti@users.sourceforge.net>
Thu, 23 Jun 2011 09:51:08 +0000 (12:51 +0300)
committerChristos Tsantilas <chtsanti@users.sourceforge.net>
Thu, 23 Jun 2011 09:51:08 +0000 (12:51 +0300)
A misstyped  if(strcmp ...) statemets has as result, all acl type in squid.conf
to be considered as "localip" acl type.

src/acl/Acl.cc

index 4ac0d7514d43ed8ce823fcc5555b88bd093af59b..39ba89ba1e92eeddd4c0a91643e940ee9d808f63 100644 (file)
@@ -122,7 +122,7 @@ ACL::ParseAclLine(ConfigParser &parser, ACL ** head)
     }
 
     // Is this ACL going to work?
-    if (strcmp(theType, "myip") != 0) {
+    if (strcmp(theType, "myip") == 0) {
         http_port_list *p = Config.Sockaddr.http;
         while (p) {
             // Bug 3239: not reliable when there is interception traffic coming
@@ -132,7 +132,7 @@ ACL::ParseAclLine(ConfigParser &parser, ACL ** head)
         }
         debugs(28, DBG_IMPORTANT, "UPGRADE: ACL 'myip' type is has been renamed to 'localip' and matches the IP the client connected to.");
         theType = "localip";
-    } else if (strcmp(theType, "myport") != 0) {
+    } else if (strcmp(theType, "myport") == 0) {
         http_port_list *p = Config.Sockaddr.http;
         while (p) {
             // Bug 3239: not reliable when there is interception traffic coming