From: robertc <> Date: Sat, 12 Jul 2003 18:39:56 +0000 (+0000) Subject: Summary: MSVC compatability fixes. X-Git-Tag: SQUID_3_0_PRE1~34 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7d9b06280742b418fb0561b58c3f51ddb39f834c;p=thirdparty%2Fsquid.git Summary: MSVC compatability fixes. Keywords: Inline a couple of template methods. Convert an anonymous struct to named. AuthUser should be a class everywhere. --- diff --git a/include/Array.h b/include/Array.h index cca0ddec2e..55163bd7e4 100644 --- a/include/Array.h +++ b/include/Array.h @@ -1,5 +1,5 @@ /* - * $Id: Array.h,v 1.12 2003/02/05 10:36:31 robertc Exp $ + * $Id: Array.h,v 1.13 2003/07/12 12:39:56 robertc Exp $ * * AUTHOR: Alex Rousskov * @@ -56,8 +56,14 @@ template class VectorIteratorBase { bool operator == (VectorIteratorBase const &rhs); VectorIteratorBase & operator ++(); VectorIteratorBase operator ++(int); - typename C::value_type & operator *() const; - typename C::value_type * operator -> () const; + typename C::value_type & operator *() const + { + return theVector->items[pos]; + } + typename C::value_type * operator -> () const + { + return &theVector->items[pos]; + } ssize_t operator - (VectorIteratorBase const &rhs) const; bool incrementable() const; private: diff --git a/src/authenticate.h b/src/authenticate.h index 7565a960c2..9a2f87ce86 100644 --- a/src/authenticate.h +++ b/src/authenticate.h @@ -1,6 +1,6 @@ /* - * $Id: authenticate.h,v 1.9 2003/07/11 01:40:36 robertc Exp $ + * $Id: authenticate.h,v 1.10 2003/07/12 12:39:56 robertc Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -66,8 +66,10 @@ struct AuthUserIP time_t ip_expiretime; }; -struct AuthUser +class AuthUser { + +public: /* extra fields for proxy_auth */ /* this determines what scheme owns the user data. */ auth_type_t auth_type; diff --git a/src/client_side.h b/src/client_side.h index 72185f5f1d..b15751a108 100644 --- a/src/client_side.h +++ b/src/client_side.h @@ -1,6 +1,6 @@ /* - * $Id: client_side.h,v 1.4 2003/07/11 02:11:47 robertc Exp $ + * $Id: client_side.h,v 1.5 2003/07/12 12:39:56 robertc Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -80,14 +80,16 @@ int parsed_ok: this, aBool); } - struct + class DeferredParams { + + public: clientStreamNode *node; HttpReply *rep; StoreIOBuffer queuedBuffer; - } + }; - deferredparams; + DeferredParams deferredparams; off_t writtenToSocket; void pullData(); off_t getNextRangeOffset() const; diff --git a/src/typedefs.h b/src/typedefs.h index 972bd3e094..83442b44f1 100644 --- a/src/typedefs.h +++ b/src/typedefs.h @@ -1,6 +1,6 @@ /* - * $Id: typedefs.h,v 1.163 2003/07/06 21:50:56 hno Exp $ + * $Id: typedefs.h,v 1.164 2003/07/12 12:39:56 robertc Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -56,7 +56,7 @@ typedef struct _acl_name_list acl_name_list; typedef struct _acl_deny_info_list acl_deny_info_list; -typedef struct AuthUser auth_user_t; +typedef class AuthUser auth_user_t; class AuthUserRequest; typedef AuthUserRequest auth_user_request_t;