From: Francesco Chemolli Date: Sun, 2 Feb 2014 17:10:57 +0000 (+0100) Subject: Turned Vector::count and capacity protected X-Git-Tag: SQUID_3_5_0_1~379^2~14 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f9514ae84bd506834bd50c28bbc6a8f1063fa82c;p=thirdparty%2Fsquid.git Turned Vector::count and capacity protected --- diff --git a/src/HttpHeader.cc b/src/HttpHeader.cc index 5a96f5a26e..ff441802c4 100644 --- a/src/HttpHeader.cc +++ b/src/HttpHeader.cc @@ -936,7 +936,7 @@ HttpHeader::insertEntry(HttpHeaderEntry * e) assert(e); assert_eid(e->id); - debugs(55, 7, HERE << this << " adding entry: " << e->id << " at " << entries.count); + debugs(55, 7, this << " adding entry: " << e->id << " at " << entries.size()); if (CBIT_TEST(mask, e->id)) ++ Headers[e->id].stat.repCount; diff --git a/src/base/Vector.h b/src/base/Vector.h index ae3aba74fb..7ef43e2689 100644 --- a/src/base/Vector.h +++ b/src/base/Vector.h @@ -122,10 +122,9 @@ public: const E& operator [] (unsigned i) const; E* data() const { return items; } - /* Do not change these, until the entry C struct is removed */ +protected: size_t capacity; size_t count; -protected: E *items; };