]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Formatting fixes, const-ified a SBuf
authorFrancesco Chemolli <kinkie@squid-cache.org>
Sat, 12 Apr 2014 07:17:08 +0000 (09:17 +0200)
committerFrancesco Chemolli <kinkie@squid-cache.org>
Sat, 12 Apr 2014 07:17:08 +0000 (09:17 +0200)
src/acl/HttpStatus.cc
src/acl/IntRange.cc
src/acl/Ip.cc
src/acl/StringData.cc
src/acl/UserData.cc

index 72fc9d8b9c332faff37e83ec635605d9752ad4ac..df39dedfc022f8c472a4577e0874843817157919 100644 (file)
@@ -71,9 +71,8 @@ int acl_httpstatus_data::compare(acl_httpstatus_data* const& a, acl_httpstatus_d
         ret = aclHTTPStatusCompare(a, b);
 
     if (ret == 0) {
-        SBuf sa, sb;
-        sa=a->repr();
-        sb=b->repr();
+        const SBuf sa = a->repr();
+        const SBuf sb = b->repr();
         debugs(28, DBG_CRITICAL, "WARNING: '" << sa << "' is a subrange of '" << sb << "'");
         debugs(28, DBG_CRITICAL, "WARNING: because of this '" << sa << "' is ignored to keep splay tree searching predictable");
         debugs(28, DBG_CRITICAL, "WARNING: You should probably remove '" << sb << "' from the ACL named '" << AclMatchedName << "'");
index 871a1da0807e1f7818c8d7efa5d6f1c6e6748bdf..30d5ee39f49bf7a72cee13db48d6db2c334083d7 100644 (file)
@@ -108,11 +108,11 @@ ACLIntRange::clone() const
     return new ACLIntRange (*this);
 }
 
-ACLIntRange::~ACLIntRange ()
+ACLIntRange::~ACLIntRange()
 {}
 
 SBufList
-ACLIntRange::dump ()
+ACLIntRange::dump()
 {
     SBufList sl;
     CbDataListIterator<RangeType> iter(ranges);
index 64960b8bd900f33578ba62703fc18dc662458047..7a153563121dbc4d1f0353204719d3fff114306d 100644 (file)
@@ -532,12 +532,12 @@ SBufList
 ACLIP::dump() const
 {
     SBufList sl;
-    data->walk (DumpIpListWalkee, &sl);
+    data->walk(DumpIpListWalkee, &sl);
     return sl;
 }
 
 bool
-ACLIP::empty () const
+ACLIP::empty() const
 {
     return data->empty();
 }
@@ -561,6 +561,6 @@ ACLIP::match(Ip::Address &clientip)
     return !splayLastResult;
 }
 
-acl_ip_data::acl_ip_data () :addr1(), addr2(), mask(), next (NULL) {}
+acl_ip_data::acl_ip_data() :addr1(), addr2(), mask(), next (NULL) {}
 
-acl_ip_data::acl_ip_data (Ip::Address const &anAddress1, Ip::Address const &anAddress2, Ip::Address const &aMask, acl_ip_data *aNext) : addr1(anAddress1), addr2(anAddress2), mask(aMask), next(aNext) {}
+acl_ip_data::acl_ip_data(Ip::Address const &anAddress1, Ip::Address const &anAddress2, Ip::Address const &aMask, acl_ip_data *aNext) : addr1(anAddress1), addr2(anAddress2), mask(aMask), next(aNext) {}
index 60dbb544d2efe5c586c3790d0e30396025c0764a..25bd55b2285b9c9042482357eea9f663e0c71c0f 100644 (file)
@@ -37,7 +37,6 @@
 #include "acl/StringData.h"
 #include "cache_cf.h"
 #include "Debug.h"
-#include "wordlist.h"
 
 ACLStringData::ACLStringData() : values (NULL)
 {}
@@ -99,7 +98,7 @@ ACLStringData::dump()
 {
     SBufList sl;
     /* damn this is VERY inefficient for long ACL lists... filling
-     * a wordlist this way costs Sum(1,N) iterations. For instance
+     * a SBufList this way costs Sum(1,N) iterations. For instance
      * a 1000-elements list will be filled in 499500 iterations.
      */
     values->walk(aclDumpStringWalkee, &sl);
index 08af4ee6c2c3730d964e2b1ebffc4f964efd4570..62b8cb08cea04110d1599bd8979add51f051508a 100644 (file)
@@ -37,7 +37,6 @@
 #include "acl/UserData.h"
 #include "ConfigParser.h"
 #include "Debug.h"
-#include "wordlist.h"
 
 template<class T>
 inline void
@@ -110,7 +109,7 @@ ACLUserData::dump()
         sl.push_back(SBuf("-i"));
 
     /* damn this is VERY inefficient for long ACL lists... filling
-     * a wordlist this way costs Sum(1,N) iterations. For instance
+     * a SBufList this way costs Sum(1,N) iterations. For instance
      * a 1000-elements list will be filled in 499500 iterations.
      */
     if (flags.required)