]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
SourceFormat Enforcement
authorAutomatic source maintenance <squidadm@squid-cache.org>
Tue, 24 Aug 2010 00:12:54 +0000 (18:12 -0600)
committerAutomatic source maintenance <squidadm@squid-cache.org>
Tue, 24 Aug 2010 00:12:54 +0000 (18:12 -0600)
23 files changed:
src/BodyPipe.cc
src/CommCalls.h
src/HttpVersion.h
src/Server.cc
src/adaptation/Initiate.cc
src/adaptation/Iterator.cc
src/adaptation/ecap/ServiceRep.cc
src/adaptation/ecap/XactionRep.cc
src/adaptation/icap/Launcher.cc
src/adaptation/icap/Launcher.h
src/adaptation/icap/ModXact.cc
src/adaptation/icap/ServiceRep.cc
src/adaptation/icap/Xaction.cc
src/base/AsyncJob.cc
src/base/AsyncJobCalls.h
src/base/CbcPointer.h
src/client_side.cc
src/client_side_reply.cc
src/client_side_request.cc
src/ftp.cc
src/http.cc
src/ipc/Port.cc
src/ipc/UdsOp.cc

index e967bda4993af1344828ad2554c6d0f1da297000..4b8b6bd261675bd0b8c589284e98d9f7ac1cff1d 100644 (file)
@@ -42,8 +42,8 @@ public:
     typedef UnaryMemFunT<BodyProducer, BodyPipe::Pointer> Parent;
 
     BodyProducerDialer(const BodyProducer::Pointer &aProducer,
-        Parent::Method aHandler, BodyPipe::Pointer bp): 
-        Parent(aProducer, aHandler, bp) {}
+                       Parent::Method aHandler, BodyPipe::Pointer bp):
+            Parent(aProducer, aHandler, bp) {}
 
     virtual bool canDial(AsyncCall &call);
 };
@@ -57,8 +57,8 @@ public:
     typedef UnaryMemFunT<BodyConsumer, BodyPipe::Pointer> Parent;
 
     BodyConsumerDialer(const BodyConsumer::Pointer &aConsumer,
-        Parent::Method aHandler, BodyPipe::Pointer bp):
-        Parent(aConsumer, aHandler, bp) {}
+                       Parent::Method aHandler, BodyPipe::Pointer bp):
+            Parent(aConsumer, aHandler, bp) {}
 
     virtual bool canDial(AsyncCall &call);
 };
index e00754214ad96aa0de983c44f5a6abb096542fb1..84e4a72875a308653fa7c64675a410dd470306ad 100644 (file)
@@ -148,8 +148,8 @@ public:
     typedef void (C::*Method)(const Params &io);
 
     CommCbMemFunT(const CbcPointer<C> &job, Method meth): JobDialer<C>(job),
-        CommDialerParamsT<Params_>(job.get()),
-        method(meth) {}
+            CommDialerParamsT<Params_>(job.get()),
+            method(meth) {}
 
     virtual bool canDial(AsyncCall &c) {
         return JobDialer<C>::canDial(c) &&
index 43952c91f132dcdf4ceb94d6ccc9e0ba025a2608..4b90a8c811fd9dff744b3ed368df35d4fdb49bf5 100644 (file)
@@ -68,12 +68,12 @@ public:
 
     bool operator <(const HttpVersion& that) const {
         return (this->major < that.major ||
-            this->major == that.major && this->minor < that.minor);
+                this->major == that.major && this->minor < that.minor);
     }
 
     bool operator >(const HttpVersion& that) const {
         return (this->major > that.major ||
-            this->major == that.major && this->minor > that.minor);
+                this->major == that.major && this->minor > that.minor);
     }
 
     bool operator <=(const HttpVersion& that) const {
index a1eeee04dcdcdf8e137469eb27dd1d77ffa6fa97..bc70bf2fd92aa34a2d73f782f0bf719c909d43af 100644 (file)
@@ -418,7 +418,7 @@ ServerStateData::sendMoreRequestBody()
         debugs(9,3, HERE << "will write " << buf.contentSize() << " request body bytes");
         typedef CommCbMemFunT<ServerStateData, CommIoCbParams> Dialer;
         requestSender = JobCallback(93,3,
-            Dialer, this, ServerStateData::sentRequestBody);
+                                    Dialer, this, ServerStateData::sentRequestBody);
         comm_write_mbuf(fd, &buf, requestSender);
     } else {
         debugs(9,3, HERE << "will wait for more request body bytes or eof");
@@ -544,7 +544,7 @@ ServerStateData::startAdaptation(const Adaptation::ServiceGroupPointer &group, H
     }
 
     adaptedHeadSource = initiateAdaptation(
-        new Adaptation::Iterator(vrep, cause, group));
+                            new Adaptation::Iterator(vrep, cause, group));
     startedAdaptation = initiated(adaptedHeadSource);
     Must(startedAdaptation);
 }
index dcec4747703a28001018e3da161d58bf83fd5aec..ffba5bc923b7b64d4f5d5c8eef141c6db373269f 100644 (file)
@@ -19,7 +19,7 @@ public:
     typedef UnaryMemFunT<Initiator, HttpMsg*> Parent;
 
     AnswerDialer(const Parent::JobPointer &job, Parent::Method meth,
-            HttpMsg *msg): Parent(job, meth, msg) { HTTPMSGLOCK(arg1); }
+                 HttpMsg *msg): Parent(job, meth, msg) { HTTPMSGLOCK(arg1); }
     AnswerDialer(const AnswerDialer &d): Parent(d) { HTTPMSGLOCK(arg1); }
     virtual ~AnswerDialer() { HTTPMSGUNLOCK(arg1); }
 
@@ -74,7 +74,7 @@ void Adaptation::Initiate::sendAnswer(HttpMsg *msg)
 {
     assert(msg);
     CallJob(93, 5, __FILE__, __LINE__, "Initiator::noteAdaptationAnswer",
-        AnswerDialer(theInitiator, &Initiator::noteAdaptationAnswer, msg));
+            AnswerDialer(theInitiator, &Initiator::noteAdaptationAnswer, msg));
     clearInitiator();
 }
 
@@ -82,7 +82,7 @@ void Adaptation::Initiate::sendAnswer(HttpMsg *msg)
 void Adaptation::Initiate::tellQueryAborted(bool final)
 {
     CallJobHere1(93, 5, theInitiator,
-        Initiator, noteAdaptationQueryAbort, final);
+                 Initiator, noteAdaptationQueryAbort, final);
     clearInitiator();
 }
 
index 57a277ea61dce0321d7d13cec4f2052cbaf0a69f..6f46121c3894ae96190e69223d9ad3bffd66a0b9 100644 (file)
@@ -15,8 +15,8 @@
 
 
 Adaptation::Iterator::Iterator(
-        HttpMsg *aMsg, HttpRequest *aCause,
-        const ServiceGroupPointer &aGroup):
+    HttpMsg *aMsg, HttpRequest *aCause,
+    const ServiceGroupPointer &aGroup):
         AsyncJob("Iterator"),
         Adaptation::Initiate("Iterator"),
         theGroup(aGroup),
@@ -69,7 +69,7 @@ void Adaptation::Iterator::step()
     debugs(93,5, HERE << "using adaptation service: " << service->cfg().key);
 
     theLauncher = initiateAdaptation(
-        service->makeXactLauncher(theMsg, theCause));
+                      service->makeXactLauncher(theMsg, theCause));
     Must(initiated(theLauncher));
     Must(!done());
 }
index 0a5e52dcd98bb983db4520942caaa5634856da13..6d8566d4c6142d870b3d73055d06a34cf278a535 100644 (file)
@@ -58,7 +58,7 @@ bool Adaptation::Ecap::ServiceRep::wantsUrl(const String &urlPath) const
 
 Adaptation::Initiate *
 Adaptation::Ecap::ServiceRep::makeXactLauncher(HttpMsg *virgin,
-    HttpRequest *cause)
+        HttpRequest *cause)
 {
     Must(up());
     XactionRep *rep = new XactionRep(virgin, cause, Pointer(this));
index 3bc8bf11ac9b812020a887ee18fdc4d756efc683..462dc160edffaf013d35302a1cad0109883fc228 100644 (file)
@@ -15,8 +15,8 @@ CBDATA_NAMESPACED_CLASS_INIT(Adaptation::Ecap::XactionRep, XactionRep);
 
 
 Adaptation::Ecap::XactionRep::XactionRep(
-        HttpMsg *virginHeader, HttpRequest *virginCause,
-        const Adaptation::ServicePointer &aService):
+    HttpMsg *virginHeader, HttpRequest *virginCause,
+    const Adaptation::ServicePointer &aService):
         AsyncJob("Adaptation::Ecap::XactionRep"),
         Adaptation::Initiate("Adaptation::Ecap::XactionRep"),
         theService(aService),
index a0fc7795fac023b4b75c11fdeb102d2d927c26f2..f6a417cf50c1fbf6212f8c9b95311df183324cc4 100644 (file)
@@ -15,7 +15,7 @@
 
 
 Adaptation::Icap::Launcher::Launcher(const char *aTypeName,
-        Adaptation::ServicePointer &aService):
+                                     Adaptation::ServicePointer &aService):
         AsyncJob(aTypeName),
         Adaptation::Initiate(aTypeName),
         theService(aService), theXaction(0), theLaunches(0)
index a8f40be0f8c8491d03b07c2d88102f6e5cc3b723..054b96bf981ce60bee3385db48638127e9cb2a07 100644 (file)
@@ -129,7 +129,8 @@ private:
 
 inline
 std::ostream &
-operator <<(std::ostream &os, const XactAbortInfo &xai) {
+operator <<(std::ostream &os, const XactAbortInfo &xai)
+{
     return xai.print(os);
 }
 
index 97c917097cd2abecbab7a8d49d34a91cb74044f3..93b4da74c9b67b57f633eca5fa5ac22a71cd72c0 100644 (file)
@@ -38,7 +38,7 @@ Adaptation::Icap::ModXact::State::State()
 }
 
 Adaptation::Icap::ModXact::ModXact(HttpMsg *virginHeader,
-    HttpRequest *virginCause, Adaptation::Icap::ServiceRep::Pointer &aService):
+                                   HttpRequest *virginCause, Adaptation::Icap::ServiceRep::Pointer &aService):
         AsyncJob("Adaptation::Icap::ModXact"),
         Adaptation::Icap::Xaction("Adaptation::Icap::ModXact", aService),
         virginConsumed(0),
@@ -97,7 +97,7 @@ void Adaptation::Icap::ModXact::waitForService()
     state.serviceWaiting = true;
     typedef NullaryMemFunT<ModXact> Dialer;
     AsyncCall::Pointer call = JobCallback(93,5,
-        Dialer, this, Adaptation::Icap::ModXact::noteServiceReady);
+                                          Dialer, this, Adaptation::Icap::ModXact::noteServiceReady);
     service().callWhenReady(call);
 }
 
index 806a6f3344c5f3dd89fb12fc9d14cec6cb38334c..7f06646764113dda8a6bc83c7b6a6d9437512338 100644 (file)
@@ -339,7 +339,7 @@ void Adaptation::Icap::ServiceRep::callException(const std::exception &e)
 {
     clearAdaptation(theOptionsFetcher);
     debugs(93,2, "ICAP probably failed to fetch options (" << e.what() <<
-        ")" << status());
+           ")" << status());
     handleNewOptions(0);
 }
 
@@ -361,7 +361,7 @@ void Adaptation::Icap::ServiceRep::startGettingOptions()
 
     // XXX: "this" here is "self"; works until refcounting API changes
     theOptionsFetcher = initiateAdaptation(
-        new Adaptation::Icap::OptXactLauncher(this));
+                            new Adaptation::Icap::OptXactLauncher(this));
     // TODO: timeout in case Adaptation::Icap::OptXact never calls us back?
     // Such a timeout should probably be a generic AsyncStart feature.
 }
@@ -429,7 +429,7 @@ Adaptation::Icap::ServiceRep::optionsFetchTime() const
 
 Adaptation::Initiate *
 Adaptation::Icap::ServiceRep::makeXactLauncher(HttpMsg *virgin,
-    HttpRequest *cause)
+        HttpRequest *cause)
 {
     return new Adaptation::Icap::ModXactLauncher(virgin, cause, this);
 }
index e8bc9b0cb43fa7e6b1c27e1030035cb25c40e74d..9c2784eec02e07fca1c58036cba5c9a9a375394b 100644 (file)
@@ -25,7 +25,7 @@ static PconnPool *icapPconnPool = new PconnPool("ICAP Servers");
 //CBDATA_NAMESPACED_CLASS_INIT(Adaptation::Icap, Xaction);
 
 Adaptation::Icap::Xaction::Xaction(const char *aTypeName,
-    Adaptation::Icap::ServiceRep::Pointer &aService):
+                                   Adaptation::Icap::ServiceRep::Pointer &aService):
         AsyncJob(aTypeName),
         Adaptation::Initiate(aTypeName),
         icapRequest(NULL),
@@ -139,18 +139,18 @@ void Adaptation::Icap::Xaction::openConnection()
     // TODO: service bypass status may differ from that of a transaction
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall = JobCallback(93, 5,
-        TimeoutDialer, this, Adaptation::Icap::Xaction::noteCommTimedout);
+                                     TimeoutDialer, this, Adaptation::Icap::Xaction::noteCommTimedout);
     commSetTimeout(connection, TheConfig.connect_timeout(
                        service().cfg().bypass), timeoutCall);
 
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommCloseCbParams> CloseDialer;
     closer = JobCallback(93, 5,
-         CloseDialer, this, Adaptation::Icap::Xaction::noteCommClosed);
+                         CloseDialer, this, Adaptation::Icap::Xaction::noteCommClosed);
     comm_add_close_handler(connection, closer);
 
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommConnectCbParams> ConnectDialer;
     connector = JobCallback(93,3,
-        ConnectDialer, this, Adaptation::Icap::Xaction::noteCommConnected);
+                            ConnectDialer, this, Adaptation::Icap::Xaction::noteCommConnected);
     commConnectStart(connection, s.cfg().host.termedBuf(), s.cfg().port, connector);
 }
 
@@ -234,7 +234,7 @@ void Adaptation::Icap::Xaction::scheduleWrite(MemBuf &buf)
     // comm module will free the buffer
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommIoCbParams> Dialer;
     writer = JobCallback(93,3,
-        Dialer, this, Adaptation::Icap::Xaction::noteCommWrote);
+                         Dialer, this, Adaptation::Icap::Xaction::noteCommWrote);
 
     comm_write_mbuf(connection, &buf, writer);
     updateTimeout();
@@ -316,7 +316,7 @@ void Adaptation::Icap::Xaction::updateTimeout()
         // TODO: service bypass status may differ from that of a transaction
         typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommTimeoutCbParams> TimeoutDialer;
         AsyncCall::Pointer call = JobCallback(93,5,
-            TimeoutDialer, this, Adaptation::Icap::Xaction::noteCommTimedout);
+                                              TimeoutDialer, this, Adaptation::Icap::Xaction::noteCommTimedout);
 
         commSetTimeout(connection,
                        TheConfig.io_timeout(service().cfg().bypass), call);
@@ -340,7 +340,7 @@ void Adaptation::Icap::Xaction::scheduleRead()
      */
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommIoCbParams> Dialer;
     reader = JobCallback(93,3,
-        Dialer, this, Adaptation::Icap::Xaction::noteCommRead);
+                         Dialer, this, Adaptation::Icap::Xaction::noteCommRead);
 
     comm_read(connection, commBuf, readBuf.spaceSize(), reader);
     updateTimeout();
@@ -474,11 +474,11 @@ void Adaptation::Icap::Xaction::tellQueryAborted()
 {
     if (theInitiator.set()) {
         Adaptation::Icap::XactAbortInfo abortInfo(icapRequest, icapReply,
-            retriable(), repeatable());
+                retriable(), repeatable());
         Launcher *launcher = dynamic_cast<Launcher*>(theInitiator.get());
         // launcher may be nil if initiator is invalid
         CallJobHere1(91,5, CbcPointer<Launcher>(launcher),
-            Launcher, noteXactAbort, abortInfo);
+                     Launcher, noteXactAbort, abortInfo);
         clearInitiator();
     }
 }
index ab8b0ac819eee8575df81057d24d08c241078a0a..3fd55571381b7bcb88ef8c93a5f2b83825258785 100644 (file)
@@ -50,7 +50,7 @@ void AsyncJob::deleteThis(const char *aReason)
     debugs(93, 5, typeName << " will delete this, reason: " << stopReason);
     CbcPointer<AsyncJob> self(this);
     AsyncCall::Pointer fakeCall = asyncCall(93,4, "FAKE-deleteThis",
-        JobMemFun(self, &AsyncJob::deleteThis, aReason));
+                                            JobMemFun(self, &AsyncJob::deleteThis, aReason));
     inCall = fakeCall;
     callEnd();
 //    delete fakeCall;
index 1d6ebe8d9c40c788c7d4b42f23b63af6015c3ba0..ef9a285f4ba5edc0a55a0e40a86e3e58ee2af6c5 100644 (file)
@@ -90,7 +90,7 @@ class NullaryMemFunT: public JobDialer<Job>
 public:
     typedef void (Job::*Method)();
     explicit NullaryMemFunT(const CbcPointer<Job> &aJob, Method aMethod):
-        JobDialer<Job>(aJob), method(aMethod) {}
+            JobDialer<Job>(aJob), method(aMethod) {}
 
     virtual void print(std::ostream &os) const {  os << "()"; }
 
@@ -107,7 +107,7 @@ class UnaryMemFunT: public JobDialer<Job>
 public:
     typedef void (Job::*Method)(Argument1);
     explicit UnaryMemFunT(const CbcPointer<Job> &aJob, Method aMethod,
-        const Argument1 &anArg1): JobDialer<Job>(aJob),
+                          const Argument1 &anArg1): JobDialer<Job>(aJob),
             method(aMethod), arg1(anArg1) {}
 
     virtual void print(std::ostream &os) const {  os << '(' << arg1 << ')'; }
@@ -137,7 +137,7 @@ JobMemFun(const CbcPointer<C> &job, typename NullaryMemFunT<C>::Method method)
 template <class C, class Argument1>
 UnaryMemFunT<C, Argument1>
 JobMemFun(const CbcPointer<C> &job, typename UnaryMemFunT<C, Argument1>::Method method,
-       Argument1 arg1)
+          Argument1 arg1)
 {
     return UnaryMemFunT<C, Argument1>(job, method, arg1);
 }
index 62a9463b86b925f9805048c35f2f9b0b3c2f437a..622d963f9705bb7ae6c173d1162d4bd5346877ee 100644 (file)
@@ -11,7 +11,7 @@
 /**
  \ingroup CBDATAAPI
  *
- * Safely points to a cbdata-protected class (cbc), such as an AsyncJob. 
+ * Safely points to a cbdata-protected class (cbc), such as an AsyncJob.
  * When a cbc we communicate with disappears without
  * notice or a notice has not reached us yet, this class prevents
  * dereferencing the pointer to the gone cbc object.
@@ -66,7 +66,8 @@ private:
 
 template <class Cbc>
 inline
-std::ostream &operator <<(std::ostream &os, const CbcPointer<Cbc> &p) {
+std::ostream &operator <<(std::ostream &os, const CbcPointer<Cbc> &p)
+{
     return p.print(os);
 }
 
@@ -148,7 +149,8 @@ CbcPointer<Cbc>::operator ->() const
 }
 
 template <class Cbc>
-std::ostream &CbcPointer<Cbc>::print(std::ostream &os) const {
+std::ostream &CbcPointer<Cbc>::print(std::ostream &os) const
+{
     return os << cbc << '/' << lock;
 }
 
index dc6feaad7af0a81124e76aecba0aa3ae11011237..96c6348ea7ab425a3a16fc3b65bce0e94aee9dd6 100644 (file)
@@ -243,7 +243,7 @@ ConnStateData::readSomeData()
 
     typedef CommCbMemFunT<ConnStateData, CommIoCbParams> Dialer;
     reader = JobCallback(33, 5,
-                          Dialer, this, ConnStateData::clientReadRequest);
+                         Dialer, this, ConnStateData::clientReadRequest);
     comm_read(fd, in.addressToReadInto(), getAvailableBufferLength(), reader);
 }
 
@@ -1361,7 +1361,7 @@ clientSocketRecipient(clientStreamNode * node, ClientHttpRequest * http,
     // After sending Transfer-Encoding: chunked (at least), always send
     // the last-chunk if there was no error, ignoring responseFinishedOrFailed.
     const bool mustSendLastChunk = http->request->flags.chunked_reply &&
-        !http->request->flags.stream_error && !context->startOfOutput();
+                                   !http->request->flags.stream_error && !context->startOfOutput();
     if (responseFinishedOrFailed(rep, receivedData) && !mustSendLastChunk) {
         context->writeComplete(fd, NULL, 0, COMM_OK);
         PROF_stop(clientSocketRecipient);
@@ -1423,7 +1423,7 @@ ConnStateData::readNextRequest()
      */
     typedef CommCbMemFunT<ConnStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall = JobCallback(33, 5,
-        TimeoutDialer, this, ConnStateData::requestTimeout);
+                                     TimeoutDialer, this, ConnStateData::requestTimeout);
     commSetTimeout(fd, Config.Timeout.persistent_request, timeoutCall);
 
     readSomeData();
@@ -3123,7 +3123,7 @@ httpAccept(int sock, int newfd, ConnectionDetail *details,
 
     typedef CommCbMemFunT<ConnStateData, CommCloseCbParams> Dialer;
     AsyncCall::Pointer call = JobCallback(33, 5,
-        Dialer, connState, ConnStateData::connStateClosed);
+                                          Dialer, connState, ConnStateData::connStateClosed);
     comm_add_close_handler(newfd, call);
 
     if (Config.onoff.log_fqdn)
@@ -3131,7 +3131,7 @@ httpAccept(int sock, int newfd, ConnectionDetail *details,
 
     typedef CommCbMemFunT<ConnStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(33, 5,
-        TimeoutDialer, connState, ConnStateData::requestTimeout);
+                                      TimeoutDialer, connState, ConnStateData::requestTimeout);
     commSetTimeout(newfd, Config.Timeout.read, timeoutCall);
 
 #if USE_IDENT
@@ -3334,7 +3334,7 @@ httpsAccept(int sock, int newfd, ConnectionDetail *details,
                                newfd, &s->http);
     typedef CommCbMemFunT<ConnStateData, CommCloseCbParams> Dialer;
     AsyncCall::Pointer call = JobCallback(33, 5,
-                              Dialer, connState, ConnStateData::connStateClosed);
+                                          Dialer, connState, ConnStateData::connStateClosed);
     comm_add_close_handler(newfd, call);
 
     if (Config.onoff.log_fqdn)
@@ -3922,7 +3922,7 @@ void ConnStateData::pinConnection(int pinning_fd, HttpRequest *request, struct p
 
     typedef CommCbMemFunT<ConnStateData, CommCloseCbParams> Dialer;
     pinning.closeHandler = JobCallback(33, 5,
-        Dialer, this, ConnStateData::clientPinnedConnectionClosed);
+                                       Dialer, this, ConnStateData::clientPinnedConnectionClosed);
     comm_add_close_handler(pinning_fd, pinning.closeHandler);
 
 }
index d5a63c4a26c9a8656382f70ef5b40c50ff930420..339e3670c89a8c461124bec423bf3c519a15cbe3 100644 (file)
@@ -1372,7 +1372,7 @@ clientReplyContext::buildReplyHeader()
 #endif
 
     const bool maySendChunkedReply = !request->multipartRangeRequest() &&
-        (request->http_ver >= HttpVersion(1, 1));
+                                     (request->http_ver >= HttpVersion(1, 1));
 
     /* Check whether we should send keep-alive */
     if (!Config.onoff.error_pconns && reply->sline.status >= 400 && !request->flags.must_keepalive) {
@@ -1397,8 +1397,8 @@ clientReplyContext::buildReplyHeader()
 
     // Decide if we send chunked reply
     if (maySendChunkedReply &&
-        request->flags.proxy_keepalive &&
-        reply->bodySize(request->method) < 0) {
+            request->flags.proxy_keepalive &&
+            reply->bodySize(request->method) < 0) {
         debugs(88, 3, "clientBuildReplyHeader: chunked reply");
         request->flags.chunked_reply = 1;
         hdr->putStr(HDR_TRANSFER_ENCODING, "chunked");
index 211e47f0b38ba9ddccd9aa43b9b7a994b9bf4b9a..3fbe0fada2d559680bb89e33c442d3779cbcf1f8 100644 (file)
@@ -1374,7 +1374,7 @@ ClientHttpRequest::startAdaptation(const Adaptation::ServiceGroupPointer &g)
     assert(!virginHeadSource);
     assert(!adaptedBodySource);
     virginHeadSource = initiateAdaptation(
-        new Adaptation::Iterator(request, NULL, g));
+                           new Adaptation::Iterator(request, NULL, g));
 
     // we could try to guess whether we can bypass this adaptation
     // initiation failure, but it should not really happen
index 17cf80355fc5d9de5984c26948602c7a8f6c81f1..758bc5ec38e87f1304f2493f5d59b39a9f23f8de 100644 (file)
@@ -480,7 +480,7 @@ FtpStateData::FtpStateData(FwdState *theFwdState) : AsyncJob("FtpStateData"), Se
 
     typedef CommCbMemFunT<FtpStateData, CommCloseCbParams> Dialer;
     AsyncCall::Pointer closer = JobCallback(9, 5,
-        Dialer, this, FtpStateData::ctrlClosed);
+                                            Dialer, this, FtpStateData::ctrlClosed);
     ctrl.opened(theFwdState->server_fd, closer);
 
     if (request->method == METHOD_PUT)
@@ -1159,14 +1159,14 @@ FtpStateData::maybeReadVirginBody()
 
     typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-        TimeoutDialer, this, FtpStateData::ftpTimeout);
+                                      TimeoutDialer, this, FtpStateData::ftpTimeout);
     commSetTimeout(data.fd, Config.Timeout.read, timeoutCall);
 
     debugs(9,5,HERE << "queueing read on FD " << data.fd);
 
     typedef CommCbMemFunT<FtpStateData, CommIoCbParams> Dialer;
     entry->delayAwareRead(data.fd, data.readBuf->space(), read_sz,
-        JobCallback(9, 5, Dialer, this, FtpStateData::dataRead));
+                          JobCallback(9, 5, Dialer, this, FtpStateData::dataRead));
 }
 
 void
@@ -1216,7 +1216,7 @@ FtpStateData::dataRead(const CommIoCbParams &io)
         if (ignoreErrno(io.xerrno)) {
             typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
             AsyncCall::Pointer timeoutCall = JobCallback(9, 5,
-                TimeoutDialer, this, FtpStateData::ftpTimeout);
+                                             TimeoutDialer, this, FtpStateData::ftpTimeout);
             commSetTimeout(io.fd, Config.Timeout.read, timeoutCall);
 
             maybeReadVirginBody();
@@ -1529,7 +1529,7 @@ FtpStateData::writeCommand(const char *buf)
 
     typedef CommCbMemFunT<FtpStateData, CommIoCbParams> Dialer;
     AsyncCall::Pointer call = JobCallback(9, 5,
-        Dialer, this, FtpStateData::ftpWriteCommandCallback);
+                                          Dialer, this, FtpStateData::ftpWriteCommandCallback);
     comm_write(ctrl.fd,
                ctrl.last_command,
                strlen(ctrl.last_command),
@@ -1667,7 +1667,7 @@ FtpStateData::scheduleReadControlReply(int buffered_ok)
         /* XXX What about Config.Timeout.read? */
         typedef CommCbMemFunT<FtpStateData, CommIoCbParams> Dialer;
         AsyncCall::Pointer reader = JobCallback(9, 5,
-            Dialer, this, FtpStateData::ftpReadControlReply);
+                                                Dialer, this, FtpStateData::ftpReadControlReply);
         comm_read(ctrl.fd, ctrl.buf + ctrl.offset, ctrl.size - ctrl.offset, reader);
         /*
          * Cancel the timeout on the Data socket (if any) and
@@ -1681,7 +1681,7 @@ FtpStateData::scheduleReadControlReply(int buffered_ok)
 
         typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
         AsyncCall::Pointer timeoutCall = JobCallback(9, 5,
-            TimeoutDialer, this, FtpStateData::ftpTimeout);
+                                         TimeoutDialer, this, FtpStateData::ftpTimeout);
 
         commSetTimeout(ctrl.fd, Config.Timeout.read, timeoutCall);
     }
@@ -2565,7 +2565,7 @@ ftpSendPassive(FtpStateData * ftpState)
      */
     typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-        TimeoutDialer, ftpState, FtpStateData::ftpTimeout);
+                                      TimeoutDialer, ftpState, FtpStateData::ftpTimeout);
 
     commSetTimeout(ftpState->data.fd, 15, timeoutCall);
 }
@@ -2947,7 +2947,7 @@ void FtpStateData::ftpAcceptDataConnection(const CommAcceptCbParams &io)
             /* we are ony accepting once, so need to re-open the listener socket. */
             typedef CommCbMemFunT<FtpStateData, CommAcceptCbParams> acceptDialer;
             AsyncCall::Pointer acceptCall = JobCallback(11, 5,
-                                                         acceptDialer, this, FtpStateData::ftpAcceptDataConnection);
+                                            acceptDialer, this, FtpStateData::ftpAcceptDataConnection);
             data.listener = new Comm::ListenStateData(data.fd, acceptCall, false);
             return;
         }
@@ -2978,7 +2978,7 @@ void FtpStateData::ftpAcceptDataConnection(const CommAcceptCbParams &io)
 
     typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-        TimeoutDialer, this, FtpStateData::ftpTimeout);
+                                      TimeoutDialer, this, FtpStateData::ftpTimeout);
     commSetTimeout(data.fd, Config.Timeout.read, timeoutCall);
 
     /*\todo XXX We should have a flag to track connect state...
@@ -3071,7 +3071,7 @@ void FtpStateData::readStor()
 
         typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
         AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-            TimeoutDialer, this, FtpStateData::ftpTimeout);
+                                          TimeoutDialer, this, FtpStateData::ftpTimeout);
 
         commSetTimeout(data.fd, Config.Timeout.read, timeoutCall);
 
@@ -3083,7 +3083,7 @@ void FtpStateData::readStor()
         debugs(9, 3, "ftpReadStor: accepting data channel");
         typedef CommCbMemFunT<FtpStateData, CommAcceptCbParams> acceptDialer;
         AsyncCall::Pointer acceptCall = JobCallback(11, 5,
-            acceptDialer, this, FtpStateData::ftpAcceptDataConnection);
+                                        acceptDialer, this, FtpStateData::ftpAcceptDataConnection);
 
         data.listener = new Comm::ListenStateData(data.fd, acceptCall, false);
     } else {
@@ -3219,7 +3219,7 @@ ftpReadList(FtpStateData * ftpState)
         /* Accept data channel */
         typedef CommCbMemFunT<FtpStateData, CommAcceptCbParams> acceptDialer;
         AsyncCall::Pointer acceptCall = JobCallback(11, 5,
-            acceptDialer, ftpState, FtpStateData::ftpAcceptDataConnection);
+                                        acceptDialer, ftpState, FtpStateData::ftpAcceptDataConnection);
 
         ftpState->data.listener = new Comm::ListenStateData(ftpState->data.fd, acceptCall, false);
         /*
@@ -3231,7 +3231,7 @@ ftpReadList(FtpStateData * ftpState)
 
         typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
         AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-            TimeoutDialer, ftpState,FtpStateData::ftpTimeout);
+                                          TimeoutDialer, ftpState,FtpStateData::ftpTimeout);
         commSetTimeout(ftpState->data.fd, Config.Timeout.read, timeoutCall);
         return;
     } else if (!ftpState->flags.tried_nlst && code > 300) {
@@ -3281,7 +3281,7 @@ ftpReadRetr(FtpStateData * ftpState)
         /* Accept data channel */
         typedef CommCbMemFunT<FtpStateData, CommAcceptCbParams> acceptDialer;
         AsyncCall::Pointer acceptCall = JobCallback(11, 5,
-                                                     acceptDialer, ftpState, FtpStateData::ftpAcceptDataConnection);
+                                        acceptDialer, ftpState, FtpStateData::ftpAcceptDataConnection);
         ftpState->data.listener = new Comm::ListenStateData(ftpState->data.fd, acceptCall, false);
         /*
          * Cancel the timeout on the Control socket and establish one
@@ -3292,7 +3292,7 @@ ftpReadRetr(FtpStateData * ftpState)
 
         typedef CommCbMemFunT<FtpStateData, CommTimeoutCbParams> TimeoutDialer;
         AsyncCall::Pointer timeoutCall =  JobCallback(9, 5,
-            TimeoutDialer, ftpState,FtpStateData::ftpTimeout);
+                                          TimeoutDialer, ftpState,FtpStateData::ftpTimeout);
         commSetTimeout(ftpState->data.fd, Config.Timeout.read, timeoutCall);
     } else if (code >= 300) {
         if (!ftpState->flags.try_slash_hack) {
index 31f5ad62fa9f80076f850c179e8e0fcb0cad51f8..349ea4c1bb4c174f1fc48cbcb489ab7a83e189fa 100644 (file)
@@ -143,7 +143,7 @@ HttpStateData::HttpStateData(FwdState *theFwdState) : AsyncJob("HttpStateData"),
      */
     typedef CommCbMemFunT<HttpStateData, CommCloseCbParams> Dialer;
     closeHandler = JobCallback(9, 5,
-        Dialer, this, HttpStateData::httpStateConnClosed);
+                               Dialer, this, HttpStateData::httpStateConnClosed);
     comm_add_close_handler(fd, closeHandler);
 }
 
@@ -1403,7 +1403,7 @@ HttpStateData::maybeReadVirginBody()
         flags.do_next_read = 0;
         typedef CommCbMemFunT<HttpStateData, CommIoCbParams> Dialer;
         entry->delayAwareRead(fd, readBuf->space(read_size), read_size,
-            JobCallback(11, 5, Dialer, this,  HttpStateData::readReply));
+                              JobCallback(11, 5, Dialer, this,  HttpStateData::readReply));
     }
 }
 
@@ -1447,7 +1447,7 @@ HttpStateData::sendComplete(const CommIoCbParams &io)
      */
     typedef CommCbMemFunT<HttpStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(11, 5,
-        TimeoutDialer, this, HttpStateData::httpTimeout);
+                                      TimeoutDialer, this, HttpStateData::httpTimeout);
 
     commSetTimeout(fd, Config.Timeout.read, timeoutCall);
 
@@ -1989,7 +1989,7 @@ HttpStateData::sendRequest()
 
     typedef CommCbMemFunT<HttpStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(11, 5,
-        TimeoutDialer, this, HttpStateData::httpTimeout);
+                                      TimeoutDialer, this, HttpStateData::httpTimeout);
     commSetTimeout(fd, Config.Timeout.lifetime, timeoutCall);
     flags.do_next_read = 1;
     maybeReadVirginBody();
@@ -1999,12 +1999,12 @@ HttpStateData::sendRequest()
             return false;
         typedef CommCbMemFunT<HttpStateData, CommIoCbParams> Dialer;
         requestSender = JobCallback(11,5,
-            Dialer, this, HttpStateData::sentRequestBody);
+                                    Dialer, this, HttpStateData::sentRequestBody);
     } else {
         assert(!requestBodySource);
         typedef CommCbMemFunT<HttpStateData, CommIoCbParams> Dialer;
         requestSender = JobCallback(11,5,
-            Dialer, this,  HttpStateData::sendComplete);
+                                    Dialer, this,  HttpStateData::sendComplete);
     }
 
     if (_peer != NULL) {
@@ -2099,7 +2099,7 @@ HttpStateData::doneSendingRequestBody()
 
             typedef CommCbMemFunT<HttpStateData, CommIoCbParams> Dialer;
             AsyncCall::Pointer call = JobCallback(11,5,
-                Dialer, this, HttpStateData::sendComplete);
+                                                  Dialer, this, HttpStateData::sendComplete);
             comm_write(fd, "\r\n", 2, call);
         }
         return;
index c3075800d1388c642bbf56eca894ff43bc6b60c5..e4a4ab33b77b38d75f9804e99f6c50e160f2e1ce 100644 (file)
@@ -32,7 +32,7 @@ void Ipc::Port::listen()
     buf.prepForReading();
     typedef CommCbMemFunT<Port, CommIoCbParams> Dialer;
     AsyncCall::Pointer readHandler = JobCallback(54, 6,
-                                                  Dialer, this, Port::noteRead);
+                                     Dialer, this, Port::noteRead);
     comm_read(fd(), buf.raw(), buf.size(), readHandler);
 }
 
index 1c148b02fe921e3f64300963c41f05682ece8fcc..92383e790a19496a0d7a159c6932c57f53c3d1ff 100644 (file)
@@ -105,7 +105,7 @@ void Ipc::UdsSender::write()
     debugs(54, 5, HERE);
     typedef CommCbMemFunT<UdsSender, CommIoCbParams> Dialer;
     AsyncCall::Pointer writeHandler = JobCallback(54, 5,
-                                                   Dialer, this, UdsSender::wrote);
+                                      Dialer, this, UdsSender::wrote);
     comm_write(fd(), message.raw(), message.size(), writeHandler);
     writing = true;
 }