]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Author: Henrik Nordstrom <henrik@henriknordstrom.net>
authorAmos Jeffries <squid3@treenet.co.nz>
Thu, 19 Mar 2009 03:01:16 +0000 (15:01 +1200)
committerAmos Jeffries <squid3@treenet.co.nz>
Thu, 19 Mar 2009 03:01:16 +0000 (15:01 +1200)
Make GCC-4.4 happy

src/adaptation/icap/OptXact.h
src/wccp2.cc

index 4c5f7cf3f0b5145d5b417855be3c793af0700726..3fe0ec834674f9b016967ed6f496f87721ec6ee6 100644 (file)
@@ -40,9 +40,6 @@
 namespace Adaptation {
 namespace Icap {
 
-class Adaptation::Icap::Options;
-
-
 /* OptXact sends an ICAP OPTIONS request to the ICAP service,
  * parses the ICAP response, and sends it to the initiator. A NULL response
  * means the ICAP service could not be contacted or did not return any
index bb34d448044a84b70406faa1484802392883fe10..1382d270536a0ef62db07313ca9e0f0b159d9427 100644 (file)
@@ -1173,7 +1173,9 @@ wccp2HandleUdp(int sock, void *not_used)
     /* Go through the data structure */
     while (data_length > offset) {
 
-        header = (struct wccp2_item_header_t *) &wccp2_i_see_you.data[offset];
+       char *data = wccp2_i_see_you.data;
+
+        header = (struct wccp2_item_header_t *) &data[offset];
 
         switch (ntohs(header->type)) {
 
@@ -1392,6 +1394,7 @@ wccp2HandleUdp(int sock, void *not_used)
 
         for (num_caches = 0; num_caches < (int) ntohl(tmp); num_caches++) {
             /* Get a copy of the ip */
+          memset(&cache_address, 0, sizeof(cache_address)); // Make GCC happy
 
             switch (Config.Wccp2.assignment_method) {