]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
eliminate non-gcc compiler warnings
authorwessels <>
Tue, 17 Mar 1998 03:11:50 +0000 (03:11 +0000)
committerwessels <>
Tue, 17 Mar 1998 03:11:50 +0000 (03:11 +0000)
src/cf_gen.cc
src/http.cc
src/snmp_agent.cc
src/stat.cc
src/structs.h

index 693cad0e4c9a3b4b29bc4c0bc9d2e18bd349562f..793da5e82e515efc47dcff58704bace8525fc53e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: cf_gen.cc,v 1.20 1998/02/10 22:17:53 wessels Exp $
+ * $Id: cf_gen.cc,v 1.21 1998/03/16 20:11:50 wessels Exp $
  *
  * DEBUG: none
  * AUTHOR: Max Okumoto
@@ -440,7 +440,7 @@ gen_dump(Entry * head, FILE * fp)
 {
     Entry *entry;
     fprintf(fp,
-       "void\n"
+       "static void\n"
        "dump_config(StoreEntry *entry)\n"
        "{\n"
        );
index bf4c6c4a33c95baa24ed47506b5a5c0769aa29c7..73e53ae52fe6dd62add6581c69f45b52d80fc84d 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: http.cc,v 1.253 1998/03/16 17:03:26 wessels Exp $
+ * $Id: http.cc,v 1.254 1998/03/16 20:11:51 wessels Exp $
  *
  * DEBUG: section 11    Hypertext Transfer Protocol (HTTP)
  * AUTHOR: Harvest Derived
@@ -125,7 +125,7 @@ enum {
 
 static CNCB httpConnectDone;
 static CWCB httpSendComplete;
-static void *sendHeaderDone;
+static CWCB *sendHeaderDone;
 static CWCB httpSendRequestEntry;
 
 static PF httpReadReply;
index 6b17a96099b1d9282f51395bfa525038ce2ae424..069a5d9e1faf7ff96eb9337f01f262d24892a475 100644 (file)
@@ -72,7 +72,7 @@ snmpAclCheckStart(snmp_request_t * rq)
 {
     communityEntry *cp;
     for (cp = Config.Snmp.communities; cp != NULL; cp = cp->next)
-       if (!strcmp(rq->community, cp->name) && cp->acls) {
+       if (!strcmp((char *)rq->community, cp->name) && cp->acls) {
            rq->acl_checklist = aclChecklistCreate(cp->acls,
                NULL, rq->from.sin_addr, NULL, NULL);
            aclNBCheck(rq->acl_checklist, snmpAclCheckDone, rq);
@@ -111,14 +111,14 @@ snmpAclCheckDone(int answer, void *data)
        debug(49, 5) ("snmpAclCheckDone: checking.\n");
        /* access check for each variable */
 
-       if (!community_check(Community, VarPtr->name, VarPtr->name_length)) {
+       if (!community_check((char *)Community, VarPtr->name, VarPtr->name_length)) {
            debug(49, 5) ("snmpAclCheckDone: failed on community_check.\n");
            snmp_agent_parse_done(0, rq);
            return;
        }
     }
     Session->community = Community;
-    Session->community_len = strlen(Community);
+    Session->community_len = strlen((char *)Community);
     RespPDU = snmp_agent_response(PDU);
     snmp_free_pdu(PDU);
     if (RespPDU == NULL) {
index 8b33dc3fb95befc1b9f4076206427bea7fab85b7..cc7f5565ceb623ab4f733c4d2c1cce7ca506e58e 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: stat.cc,v 1.216 1998/03/12 17:51:21 wessels Exp $
+ * $Id: stat.cc,v 1.217 1998/03/16 20:11:53 wessels Exp $
  *
  * DEBUG: section 18    Cache Manager Statistics
  * AUTHOR: Harvest Derived
@@ -137,7 +137,7 @@ static int NCountHist = 0;
 static StatCounters CountHourHist[N_COUNT_HOUR_HIST];
 static int NCountHourHist = 0;
 
-void
+static void
 statUtilization(StoreEntry * e)
 {
     storeAppendPrintf(e, "Cache Utilisation:\n");
@@ -182,7 +182,7 @@ statUtilization(StoreEntry * e)
     statCountersDump(e);
 }
 
-void
+static void
 stat_io_get(StoreEntry * sentry)
 {
     int i;
@@ -359,13 +359,13 @@ statObjects(StoreEntry * sentry, int vm_or_not)
     }
 }
 
-void
+static void
 stat_objects_get(StoreEntry * e)
 {
     statObjects(e, 0);
 }
 
-void
+static void
 stat_vmobjects_get(StoreEntry * e)
 {
     statObjects(e, 1);
@@ -390,7 +390,7 @@ fdRemoteAddr(const fde * f)
     return buf;
 }
 
-void
+static void
 statFiledescriptors(StoreEntry * sentry)
 {
     int i;
@@ -420,7 +420,7 @@ statFiledescriptors(StoreEntry * sentry)
     }
 }
 
-void
+static void
 info_get(StoreEntry * sentry)
 {
     struct rusage rusage;
@@ -788,7 +788,7 @@ statCountersInitSpecial(StatCounters * C)
 }
 
 /* add special cases here as they arrive */
-void
+static void
 statCountersClean(StatCounters * C)
 {
     assert(C);
@@ -802,7 +802,7 @@ statCountersClean(StatCounters * C)
 }
 
 /* add special cases here as they arrive */
-void
+static void
 statCountersCopy(StatCounters * dest, const StatCounters * orig)
 {
     assert(dest && orig);
@@ -922,19 +922,19 @@ statCountersDump(StoreEntry * sentry)
        tvSubDsec(f->timestamp, current_time));
 }
 
-void
+static void
 statCounters(StoreEntry * e)
 {
     statCountersDump(e);
 }
 
-void
+static void
 statAvg5min(StoreEntry * e)
 {
     statAvgDump(e, 5, 0);
 }
 
-void
+static void
 statAvg60min(StoreEntry * e)
 {
     statAvgDump(e, 60, 0);
index 894ea9fa19339269f48106027a2f9b86ab22ea34..a4536ecad368ce0fbae7420fb90f8bd44f48ef1d 100644 (file)
@@ -61,8 +61,8 @@ struct _snmpconf {
 };
 
 struct _snmp_request_t {
-    char *buf;
-    char *outbuf;
+    u_char *buf;
+    u_char *outbuf;
     int len;
     int sock;
     long reqid;
@@ -70,7 +70,7 @@ struct _snmp_request_t {
     struct sockaddr_in from;
     struct snmp_pdu *PDU;
     aclCheck_t *acl_checklist;
-    char *community;
+    u_char *community;
 };
 
 typedef struct _viewEntry {