if (abortOnBadEntry("store entry aborted while kick producer callback"))
return;
- if(!adaptedBodySource)
+ if (!adaptedBodySource)
return;
handleMoreAdaptedBodyAvailable();
const size_t bytesWanted = entry->bytesWanted(Range<size_t>(0, contentSize));
const size_t spaceAvailable = bytesWanted > 0 ? (bytesWanted + 1) : 0;
- if (spaceAvailable < contentSize ) {
+ if (spaceAvailable < contentSize ) {
// No or partial body data consuming
typedef NullaryMemFunT<ServerStateData> Dialer;
AsyncCall::Pointer call = asyncCall(93, 5, "ServerStateData::resumeBodyStorage",
"response body at offset " << adaptedBodySource->consumedSize());
return;
}
-
+
if (spaceAvailable < contentSize ) {
debugs(11, 5, HERE << "postponing storage of " <<
(contentSize - spaceAvailable) << " body bytes");
contentSize = spaceAvailable;
}
-
+
debugs(11,5, HERE << "storing " << contentSize << " bytes of adapted " <<
"response body at offset " << adaptedBodySource->consumedSize());
-
+
BodyPipeCheckout bpc(*adaptedBodySource);
const StoreIOBuffer ioBuf(&bpc.buf, currentOffset, contentSize);
currentOffset += ioBuf.length;
{
if (abortOnBadEntry("entry went bad while waiting for adapted body eof"))
return;
-
- // end consumption if we consumed everything
+
+ // end consumption if we consumed everything
if (adaptedBodySource != NULL && adaptedBodySource->exhausted())
endAdaptedBodyConsumption();
// else resumeBodyStorage() will eventually consume the rest
void
ClientHttpRequest::resumeBodyStorage()
{
- if(!adaptedBodySource)
+ if (!adaptedBodySource)
return;
noteMoreBodyDataAvailable(adaptedBodySource);
};
/// The set of custom formats defined in squid.conf
-///
+///
class FmtConfig
{
public:
snprintf(tmp, sizeof(tmp), "SSL_ERR=%d", al->request->errDetail);
out = tmp;
}
- } else
+ } else
#endif
- if (al->request && al->request->errDetail != ERR_DETAIL_NONE) {
- if (al->request->errDetail > ERR_DETAIL_START &&
- al->request->errDetail < ERR_DETAIL_MAX)
- out = errorDetailName(al->request->errDetail);
- else {
- if (al->request->errDetail >= ERR_DETAIL_EXCEPTION_START)
- snprintf(tmp, sizeof(tmp), "%s=0x%X",
- errorDetailName(al->request->errDetail), (uint32_t) al->request->errDetail);
- else
- snprintf(tmp, sizeof(tmp), "%s=%d",
- errorDetailName(al->request->errDetail), al->request->errDetail);
- out = tmp;
+ if (al->request && al->request->errDetail != ERR_DETAIL_NONE) {
+ if (al->request->errDetail > ERR_DETAIL_START &&
+ al->request->errDetail < ERR_DETAIL_MAX)
+ out = errorDetailName(al->request->errDetail);
+ else {
+ if (al->request->errDetail >= ERR_DETAIL_EXCEPTION_START)
+ snprintf(tmp, sizeof(tmp), "%s=0x%X",
+ errorDetailName(al->request->errDetail), (uint32_t) al->request->errDetail);
+ else
+ snprintf(tmp, sizeof(tmp), "%s=%d",
+ errorDetailName(al->request->errDetail), al->request->errDetail);
+ out = tmp;
+ }
}
- }
break;
case LFT_SQUID_HIERARCHY:
{
/// One entry in a table of format tokens.
-class TokenTableEntry {
+class TokenTableEntry
+{
public:
/// the config file ASCII representation for this token
/// just the base tag bytes, excluding any option syntax bytes
request->detailError(errorState->type, errorState->detail->errorNo());
else
#endif
- request->detailError(errorState->type, errorState->xerrno);
+ request->detailError(errorState->type, errorState->xerrno);
}
/**
if (!deferredProducer)
deferredProducer = producer;
else
- debugs(20, 5, HERE << "Deferred producer call is allready set to: " <<
+ debugs(20, 5, HERE << "Deferred producer call is allready set to: " <<
*deferredProducer << ", requested call: " << *producer);
}
void
StoreEntry::kickProducer()
{
- if(deferredProducer != NULL){
+ if (deferredProducer != NULL) {
ScheduleCallHere(deferredProducer);
deferredProducer = NULL;
}