]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Summary: Merge in 6th set of windows changes from Guido
authorrobertc <>
Sun, 9 Mar 2003 19:29:40 +0000 (19:29 +0000)
committerrobertc <>
Sun, 9 Mar 2003 19:29:40 +0000 (19:29 +0000)
Keywords:

Merge in 6th set of windows changes from Guido

12 files changed:
src/HttpHdrCc.cc
src/HttpHeader.cc
src/HttpReply.cc
src/ICP.h
src/client_db.cc
src/comm.h
src/dns.cc
src/dns_internal.cc
src/errorpage.cc
src/mem.cc
src/url.cc
src/urn.cc

index f1300e76f32aeedf32699c75577fee0450fcd6bf..85830ba4a9de829ae22058d5085d7378df4c8835 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpHdrCc.cc,v 1.25 2003/02/21 22:50:05 robertc Exp $
+ * $Id: HttpHdrCc.cc,v 1.26 2003/03/09 12:29:40 robertc Exp $
  *
  * DEBUG: section 65    HTTP Cache Control Header
  * AUTHOR: Alex Rousskov
@@ -59,7 +59,8 @@ HttpHeaderFieldInfo *CcFieldsInfo = NULL;
 
 http_hdr_cc_type &operator++ (http_hdr_cc_type &aHeader)
 {
-    aHeader = (http_hdr_cc_type)(++(int)aHeader);
+    int tmp = (int)aHeader;
+    aHeader = (http_hdr_cc_type)(++tmp);
     return aHeader;
 }
 
index 20b678f24b8cec735320303d5cf07bb5d6e495b1..d7a518e8626d70237a1d53d63375c426e2d252d5 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpHeader.cc,v 1.87 2003/03/06 11:51:55 robertc Exp $
+ * $Id: HttpHeader.cc,v 1.88 2003/03/09 12:29:40 robertc Exp $
  *
  * DEBUG: section 55    HTTP Header
  * AUTHOR: Alex Rousskov
@@ -141,7 +141,8 @@ static HttpHeaderFieldInfo *Headers = NULL;
 
 http_hdr_type &operator++ (http_hdr_type &aHeader)
 {
-    aHeader = (http_hdr_type)(++(int)aHeader);
+    int tmp = (int)aHeader;
+    aHeader = (http_hdr_type)(++tmp);
     return aHeader;
 }
 
index 2e1629c5c91f5f42566e9b404914d40f6428196d..239192b9749f5cd85f943bee5f31e75129dcc8d1 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpReply.cc,v 1.56 2003/03/06 11:51:55 robertc Exp $
+ * $Id: HttpReply.cc,v 1.57 2003/03/09 12:29:40 robertc Exp $
  *
  * DEBUG: section 58    HTTP Reply (Response)
  * AUTHOR: Alex Rousskov
@@ -53,7 +53,8 @@ static http_hdr_type Denied304HeadersArr[] =
 
 HttpMsgParseState &operator++ (HttpMsgParseState &aState)
 {
-    aState = (HttpMsgParseState)(++(int)aState);
+    int tmp = (int)aState;
+    aState = (HttpMsgParseState)(++tmp);
     return aState;
 }
 
index 088e43b317a884df334028c71ec3a14c990279c6..c41d1da4a43ea97e2a58f5f9716e9bdce8ce5da9 100644 (file)
--- a/src/ICP.h
+++ b/src/ICP.h
@@ -1,6 +1,6 @@
 
 /*
- * $Id: ICP.h,v 1.4 2003/02/21 22:50:05 robertc Exp $
+ * $Id: ICP.h,v 1.5 2003/03/09 12:29:40 robertc Exp $
  *
  *
  * SQUID Web Proxy Cache          http://www.squid-cache.org/
@@ -65,7 +65,8 @@ struct _icp_common_t
 
 inline icp_opcode & operator++ (icp_opcode & aCode)
 {
-    aCode = (icp_opcode) (++(int) aCode);
+    int tmp = (int) aCode;
+    aCode = (icp_opcode) (++tmp);
     return aCode;
 }
 
index 80151b211221b4cce92eb700d1fb48074558fc57..8debe29379f0feec96ecf1c8fc0a054c8bf69f06 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: client_db.cc,v 1.57 2003/02/21 22:50:07 robertc Exp $
+ * $Id: client_db.cc,v 1.58 2003/03/09 12:29:40 robertc Exp $
  *
  * DEBUG: section 0     Client Database
  * AUTHOR: Duane Wessels
@@ -201,7 +201,8 @@ clientdbCutoffDenied(struct in_addr addr)
 
 log_type &operator++ (log_type &aLogType)
 {
-    aLogType = (log_type)(++(int)aLogType);
+    int tmp = (int)aLogType;
+    aLogType = (log_type)(++tmp);
     return aLogType;
 }
 
index dab6c18c8bfc9aa5ecd3f44ce768955478d15ddd..1f263b84ac941b8ecc023b606aceac64aa4951a7 100644 (file)
@@ -4,7 +4,7 @@
 #include "StoreIOBuffer.h"
 
 typedef void IOFCB(int fd, StoreIOBuffer recievedData, comm_err_t flag, int xerrno, void *data);
-typedef void IOWCB(int fd, char *data, size_t len, comm_err_t flag, int xerrno, void *data);
+typedef void IOWCB(int fd, char *buffer, size_t len, comm_err_t flag, int xerrno, void *data);
 /* fill sb with up to length data from fd */
 extern void comm_fill_immediate(int fd, StoreIOBuffer sb, IOFCB *callback, void *data);
 
index a6ba23cba447acd4beb1666e951219f3a0c8184b..40fb68321eba0cb6675846b0902982717dea56ab 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: dns.cc,v 1.91 2003/02/21 22:50:08 robertc Exp $
+ * $Id: dns.cc,v 1.92 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 34    Dnsserver interface
  * AUTHOR: Harvest Derived
 #include "squid.h"
 #include "Store.h"
 
+/* MS VisualStudio Projects are monolitich, so we need the following
+   #if to include the external DNS code in compile process when
+   using external DNS.
+ */
+#if USE_DNSSERVERS
 static helper *dnsservers = NULL;
 
 static void
@@ -167,3 +172,4 @@ snmp_netDnsFn(variable_list * Var, snint * ErrP)
 }
 
 #endif /*SQUID_SNMP */
+#endif /* USE_DNSSERVERS */
index 4f261f89bf4aa7c8ee1f4233953638ff5865e5fd..2b44ea2cd82cc520aed525f6e78154b436667c6c 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: dns_internal.cc,v 1.56 2003/03/02 09:59:32 hno Exp $
+ * $Id: dns_internal.cc,v 1.57 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 78    DNS lookups; interacts with lib/rfc1035.c
  * AUTHOR: Duane Wessels
 #include "Store.h"
 #include "comm.h"
 
+/* MS VisualStudio Projects are monolitich, so we need the following
+   #ifndef to exclude the internal DNS code from compile process when
+   using external DNS process.
+ */
+#ifndef USE_DNSSERVERS
 #if defined(_SQUID_MSWIN_) || defined(_SQUID_CYGWIN_)
 #include <windows.h>
 #endif
@@ -91,7 +96,9 @@ static OBJH idnsStats;
 static void idnsAddNameserver(const char *buf);
 static void idnsFreeNameservers(void);
 static void idnsParseNameservers(void);
+#ifndef _SQUID_MSWIN_
 static void idnsParseResolvConf(void);
+#endif
 #if defined(_SQUID_MSWIN_) || defined(_SQUID_CYGWIN_)
 static void idnsParseWIN32Registry(void);
 #endif
@@ -167,6 +174,7 @@ idnsParseNameservers(void)
     }
 }
 
+#ifndef _SQUID_MSWIN_
 static void
 idnsParseResolvConf(void)
 {
@@ -180,7 +188,7 @@ idnsParseResolvConf(void)
         return;
     }
 
-#if defined(_SQUID_MSWIN_) || defined(_SQUID_CYGWIN_)
+#if defined(_SQUID_CYGWIN_)
     setmode(fileno(fp), O_TEXT);
 
 #endif
@@ -207,6 +215,8 @@ idnsParseResolvConf(void)
     fclose(fp);
 }
 
+#endif
+
 #if defined(_SQUID_MSWIN_) || defined(_SQUID_CYGWIN_)
 static void
 idnsParseWIN32Registry(void)
@@ -917,3 +927,4 @@ snmp_netIdnsFn(variable_list * Var, snint * ErrP)
 }
 
 #endif /*SQUID_SNMP */
+#endif /* USE_DNSSERVERS */
index a52a983c7db3e9681082eb8ef05f557bab72fe65..33b2304601860d7b3660c6f676906eb94f8b7e69 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: errorpage.cc,v 1.186 2003/02/25 02:17:54 hno Exp $
+ * $Id: errorpage.cc,v 1.187 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 4     Error Generation
  * AUTHOR: Duane Wessels
@@ -109,7 +109,8 @@ static CWCB errorSendComplete;
 
 err_type &operator++ (err_type &anErr)
 {
-    anErr = (err_type)(++(int)anErr);
+    int tmp = (int)anErr;
+    anErr = (err_type)(++tmp);
     return anErr;
 }
 
index a3a8eb45dafd534e2f97feb5d0830b78034dec6d..7f5dfd3c0ee9ad467cc7197b4465814700faf548 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: mem.cc,v 1.76 2003/03/06 11:51:56 robertc Exp $
+ * $Id: mem.cc,v 1.77 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 13    High Level Memory Pool Management
  * AUTHOR: Harvest Derived
@@ -430,7 +430,8 @@ Mem::Init(void)
 
 mem_type &operator++ (mem_type &aMem)
 {
-    aMem = (mem_type)(++(int)aMem);
+    int tmp = (int)aMem;
+    aMem = (mem_type)(++tmp);
     return aMem;
 }
 
index cf9833f504f1567d6f75a076837b3547f40c7bc7..22b1840b712361075a884706b0c8551a818569d7 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: url.cc,v 1.143 2003/02/21 22:50:12 robertc Exp $
+ * $Id: url.cc,v 1.144 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 23    URL Parsing
  * AUTHOR: Duane Wessels
@@ -184,7 +184,8 @@ urlInitialize(void)
 
 method_t &operator++ (method_t &aMethod)
 {
-    aMethod = (method_t)(++(int)aMethod);
+    int tmp = (int)aMethod;
+    aMethod = (method_t)(++tmp);
     return aMethod;
 }
 
index f70723cfacb119a355d9a36eb1f556dbefdebb36..abed6cb77690604285c3715319743bbb4ec8e165 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: urn.cc,v 1.83 2003/03/06 06:21:38 robertc Exp $
+ * $Id: urn.cc,v 1.84 2003/03/09 12:29:41 robertc Exp $
  *
  * DEBUG: section 52    URN Parsing
  * AUTHOR: Kostas Anagnostakis
@@ -114,7 +114,8 @@ UrnState::operator new (size_t byteCount)
 void
 UrnState::operator delete (void *address)
 {
-    cbdataFree ((UrnState *)address);
+    UrnState * tmp = (UrnState *)address;
+    cbdataFree (tmp);
 }
 
 UrnState::~UrnState ()