From: Automatic source maintenance Date: Sat, 27 Oct 2012 00:13:19 +0000 (-0600) Subject: SourceFormat Enforcement X-Git-Tag: SQUID_3_4_0_1~546 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ffb821513f6d3f369dba133df51803a293388fb4;p=thirdparty%2Fsquid.git SourceFormat Enforcement --- diff --git a/src/HttpRequest.cc b/src/HttpRequest.cc index a8a95803f8..f000306907 100644 --- a/src/HttpRequest.cc +++ b/src/HttpRequest.cc @@ -585,8 +585,7 @@ HttpRequest::maybeCacheable() if (!flags.hostVerified && (flags.intercepted || flags.spoofClientIp)) return false; - switch(protocol) - { + switch (protocol) { case AnyP::PROTO_HTTP: if (!method.respMaybeCacheable()) return false; @@ -603,7 +602,7 @@ HttpRequest::maybeCacheable() case AnyP::PROTO_CACHE_OBJECT: return false; - //case AnyP::PROTO_FTP: + //case AnyP::PROTO_FTP: default: break; } diff --git a/src/HttpRequestMethod.cc b/src/HttpRequestMethod.cc index 2f69b9379e..4fe6fc960b 100644 --- a/src/HttpRequestMethod.cc +++ b/src/HttpRequestMethod.cc @@ -78,11 +78,10 @@ HttpRequestMethod::isHttpSafe() const // NOTE: // All known RFCs which register methods are listed in comments. - // if there is one not listed which defines methods, it needs + // if there is one not listed which defines methods, it needs // checking and adding. If only to say it is known to define none. - switch(theMethod) - { + switch (theMethod) { // RFC 2068 - none // RFC 2616 section 9.1.1 @@ -121,11 +120,10 @@ HttpRequestMethod::isIdempotent() const // NOTE: // All known RFCs which register methods are listed in comments. - // if there is one not listed which defines methods, it needs + // if there is one not listed which defines methods, it needs // checking and adding. If only to say it is known to define none. - switch(theMethod) - { + switch (theMethod) { // RFC 2068 - TODO check LINK/UNLINK definition // RFC 2616 section 9.1.2 @@ -166,8 +164,7 @@ HttpRequestMethod::respMaybeCacheable() const { // Only a few methods are defined as cacheable. // All other methods from the below RFC are "MUST NOT cache" - switch(theMethod) - { + switch (theMethod) { // RFC 2616 section 9 case Http::METHOD_GET: case Http::METHOD_HEAD: diff --git a/src/Notes.h b/src/Notes.h index 5a78b8f168..fab5922d86 100644 --- a/src/Notes.h +++ b/src/Notes.h @@ -9,7 +9,6 @@ #include #endif - class HttpRequest; class HttpReply; @@ -57,7 +56,8 @@ class ConfigParser; /** * Used to store a notes list. */ -class Notes { +class Notes +{ public: typedef Vector NotesList; typedef NotesList::iterator iterator; ///< iterates over the notes list @@ -95,7 +95,8 @@ private: Note::Pointer add(const String ¬eKey); }; -class NotePairs : public HttpHeader { +class NotePairs : public HttpHeader +{ public: NotePairs() : HttpHeader(hoNote) {} }; diff --git a/src/adaptation/ecap/XactionRep.cc b/src/adaptation/ecap/XactionRep.cc index 028a642404..01c7aaeae9 100644 --- a/src/adaptation/ecap/XactionRep.cc +++ b/src/adaptation/ecap/XactionRep.cc @@ -219,7 +219,7 @@ Adaptation::Ecap::XactionRep::start() makingVb = opNever; // there is nothing to deliver HttpRequest *request = dynamic_cast (theCauseRep ? - theCauseRep->raw().header : theVirginRep.raw().header); + theCauseRep->raw().header : theVirginRep.raw().header); Must(request); HttpReply *reply = dynamic_cast(theVirginRep.raw().header); diff --git a/src/format/Format.cc b/src/format/Format.cc index d98bc76b68..d07bfc96bd 100644 --- a/src/format/Format.cc +++ b/src/format/Format.cc @@ -1042,7 +1042,7 @@ Format::Format::assemble(MemBuf &mb, const AccessLogEntry::Pointer &al, int logS #endif case LFT_NOTE: if (fmt->data.string) { - sb = al->notes.getByName(fmt->data.string); + sb = al->notes.getByName(fmt->data.string); out = sb.termedBuf(); quote = 1; } else { diff --git a/src/http/MethodType.h b/src/http/MethodType.h index b66c9fad5e..ce64956905 100644 --- a/src/http/MethodType.h +++ b/src/http/MethodType.h @@ -4,7 +4,7 @@ namespace Http { -// see IANA registry: +// see IANA registry: // also: https://datatracker.ietf.org/doc/draft-ietf-httpbis-method-registrations typedef enum _method_t { METHOD_NONE = 0,