]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
SourceFormat Enforcement
authorAutomatic source maintenance <squidadm@squid-cache.org>
Wed, 28 Jul 2010 01:23:12 +0000 (19:23 -0600)
committerAutomatic source maintenance <squidadm@squid-cache.org>
Wed, 28 Jul 2010 01:23:12 +0000 (19:23 -0600)
src/cache_cf.cc
src/ip/IpIntercept.cc
src/ipcache.cc

index f2863d2521634960922d8f49c5938c2498d9f0d7..280308d1b9b795f979d3ccb00c8e45b7155c0102 100644 (file)
@@ -2840,21 +2840,20 @@ parse_IpAddress_list_token(IpAddress_list ** head, char *token)
             debugs(3, DBG_CRITICAL, "FATAL: IPv6 is not enabled.");
             self_destruct();
         }
-    } else
-        if ((t = strchr(token, ':'))) {
-            /* host:port */
-            host = token;
-            *t = '\0';
-            port = xatos(t + 1);
-
-            if (0 == port)
-                self_destruct();
-        } else if ((port = strtol(token, &tmp, 10)), !*tmp) {
-            /* port */
-        } else {
-            host = token;
-            port = 0;
-        }
+    } else if ((t = strchr(token, ':'))) {
+        /* host:port */
+        host = token;
+        *t = '\0';
+        port = xatos(t + 1);
+
+        if (0 == port)
+            self_destruct();
+    } else if ((port = strtol(token, &tmp, 10)), !*tmp) {
+        /* port */
+    } else {
+        host = token;
+        port = 0;
+    }
 
     if (NULL == host)
         ipa.SetAnyAddr();
index e35aabe7df35f2ec4d84633e3803a86114eb56ad..5221a0f4220890606007580ba7a3d1e2d4ac71de 100644 (file)
@@ -451,7 +451,7 @@ IpIntercept::ProbeForTproxy(IpAddress &test)
         /* TPROXYv2 is not IPv6 capable. Force wildcard sockets to IPv4. Die on IPv6 IPs */
         debugs(3, DBG_IMPORTANT, "Disabling IPv6 on port " << test << " (TPROXYv2 interception enabled)");
         if ( test.IsIPv6() && !test.SetIPv4() ) {
-           debugs(3, DBG_CRITICAL, "IPv6 requires TPROXYv4 support. You only have TPROXYv2 for " << test );
+            debugs(3, DBG_CRITICAL, "IPv6 requires TPROXYv4 support. You only have TPROXYv2 for " << test );
             return false;
         }
     }
index f222623465fdea87b86ac7b2d451e44de65a786d..9a45d6f01de95bcfc6185f3e05c3d25daf56c394 100644 (file)
@@ -992,8 +992,7 @@ ipcacheMergeIPLists(const IpAddress *aaddrs, const int alen,
                 ip4ptrs[num_ip4] = &aaddrs[t];
                 num_ip4++;
             }
-        }
-        else if (aaddrs[t].IsIPv6()) {
+        } else if (aaddrs[t].IsIPv6()) {
             debugs(14,8, HERE << "A[" << t << "]=IPv6 " << aaddrs[t]);
             // check against IPv6 pruned list
             for (c = 0; c <= num_ip6; c++) {
@@ -1017,8 +1016,7 @@ ipcacheMergeIPLists(const IpAddress *aaddrs, const int alen,
                 ip4ptrs[num_ip4] = &baddrs[t];
                 num_ip4++;
             }
-        }
-        else if (baddrs[t].IsIPv6()) {
+        } else if (baddrs[t].IsIPv6()) {
             // check against IPv6 pruned list
             for (c = 0; c <= num_ip6; c++) {
                 if (ip6ptrs[c] && baddrs[t] == *ip6ptrs[c]) break; // duplicate.