]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
detect-address: fix -Wshadow warnings
authorVictor Julien <victor@inliniac.net>
Mon, 28 Nov 2016 11:36:41 +0000 (12:36 +0100)
committerVictor Julien <victor@inliniac.net>
Mon, 28 Nov 2016 12:55:20 +0000 (13:55 +0100)
src/detect-engine-address.c

index af34c07c218201390f03dc13638313cf4d8c71d1..4720d5e31ddcdc5f8ca3815ab9ca1a62879a1e9b 100644 (file)
@@ -3261,11 +3261,11 @@ int AddressTestAddressGroupSetup04(void)
             r = DetectAddressParse(NULL, gh, "1.2.3.3");
             if (r == 0 && gh->ipv4_head != prev_head &&
                 gh->ipv4_head != NULL && gh->ipv4_head->next == prev_head) {
-                DetectAddress *prev_head = gh->ipv4_head;
+                DetectAddress *ph = gh->ipv4_head;
 
                 r = DetectAddressParse(NULL, gh, "1.2.3.2");
-                if (r == 0 && gh->ipv4_head != prev_head &&
-                    gh->ipv4_head != NULL && gh->ipv4_head->next == prev_head) {
+                if (r == 0 && gh->ipv4_head != ph &&
+                    gh->ipv4_head != NULL && gh->ipv4_head->next == ph) {
                     result = 1;
                 }
             }
@@ -3289,11 +3289,11 @@ int AddressTestAddressGroupSetup05(void)
             r = DetectAddressParse(NULL, gh, "1.2.3.3");
             if (r == 0 && gh->ipv4_head == prev_head &&
                 gh->ipv4_head != NULL && gh->ipv4_head->next != prev_head) {
-                DetectAddress *prev_head = gh->ipv4_head;
+                DetectAddress *ph = gh->ipv4_head;
 
                 r = DetectAddressParse(NULL, gh, "1.2.3.4");
-                if (r == 0 && gh->ipv4_head == prev_head &&
-                    gh->ipv4_head != NULL && gh->ipv4_head->next != prev_head) {
+                if (r == 0 && gh->ipv4_head == ph &&
+                    gh->ipv4_head != NULL && gh->ipv4_head->next != ph) {
                     result = 1;
                 }
             }
@@ -3674,11 +3674,11 @@ int AddressTestAddressGroupSetup17(void)
             r = DetectAddressParse(NULL, gh, "2001::3");
             if (r == 0 && gh->ipv6_head != prev_head &&
                 gh->ipv6_head != NULL && gh->ipv6_head->next == prev_head) {
-                DetectAddress *prev_head = gh->ipv6_head;
+                DetectAddress *ph = gh->ipv6_head;
 
                 r = DetectAddressParse(NULL, gh, "2001::2");
-                if (r == 0 && gh->ipv6_head != prev_head &&
-                    gh->ipv6_head != NULL && gh->ipv6_head->next == prev_head) {
+                if (r == 0 && gh->ipv6_head != ph &&
+                    gh->ipv6_head != NULL && gh->ipv6_head->next == ph) {
                     result = 1;
                 }
             }
@@ -3702,11 +3702,11 @@ int AddressTestAddressGroupSetup18(void)
             r = DetectAddressParse(NULL, gh, "2001::3");
             if (r == 0 && gh->ipv6_head == prev_head &&
                 gh->ipv6_head != NULL && gh->ipv6_head->next != prev_head) {
-                DetectAddress *prev_head = gh->ipv6_head;
+                DetectAddress *ph = gh->ipv6_head;
 
                 r = DetectAddressParse(NULL, gh, "2001::4");
-                if (r == 0 && gh->ipv6_head == prev_head &&
-                    gh->ipv6_head != NULL && gh->ipv6_head->next != prev_head) {
+                if (r == 0 && gh->ipv6_head == ph &&
+                    gh->ipv6_head != NULL && gh->ipv6_head->next != ph) {
                     result = 1;
                 }
             }