if (head) {
List<C> *tempNode = NULL;
- for (tempNode = head; tempNode->next; tempNode = tempNode->next)
-
- ;
+ for (tempNode = head; tempNode->next; tempNode = tempNode->next);
tempNode->next = node;
} else
head = node;
/* explicit template instantiation required for some systems */
-template class ACLStrategised<char const *>
-
-;
-template class ACLRequestHeaderStrategy<HDR_USER_AGENT>
-
-;
+template class ACLStrategised<char const *>;
+template class ACLRequestHeaderStrategy<HDR_USER_AGENT>;
ACL::Prototype ACLBrowser::RegistryProtoype(&ACLBrowser::RegistryEntry_, "browser");
{
Flags() : strict(0){}
-unsigned int strict:
- 1;
- }
-
- flags;
+ unsigned int strict:1;
+ } flags;
};
MEMPROXY_CLASS_INLINE(ACLMaxUserIP) /**DOCS_NOSEMI*/
/* explicit template instantiation required for some systems */
-template class ACLStrategised<HttpRequestMethod>
-
-;
+template class ACLStrategised<HttpRequestMethod>;
ACL::Prototype ACLMethod::RegistryProtoype(&ACLMethod::RegistryEntry_, "method");
List<HttpRequestMethod> **Tail;
char *t = NULL;
- for (Tail = &values; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = &values; *Tail; Tail = &((*Tail)->next));
while ((t = strtokFile())) {
List<HttpRequestMethod> *q = new List<HttpRequestMethod> (HttpRequestMethod(t, NULL));
*(Tail) = q;
/* explicit template instantiation required for some systems */
-template class ACLStrategised<int>
-
-;
+template class ACLStrategised<int>;
ACL::Prototype ACLMyPort::RegistryProtoype(&ACLMyPort::RegistryEntry_, "myport");
/* explicit template instantiation required for some systems */
-template class ACLStrategised<protocol_t>
-
-;
+template class ACLStrategised<protocol_t>;
ACL::Prototype ACLProtocol::RegistryProtoype(&ACLProtocol::RegistryEntry_, "proto");
ACLProtocolStrategy::match (ACLData<MatchType> * &data, ACLChecklist *checklist)
{
return data->match (checklist->request->protocol);
- ;
}
ACLProtocolStrategy *
List<protocol_t> **Tail;
char *t = NULL;
- for (Tail = &values; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = &values; *Tail; Tail = &((*Tail)->next));
while ((t = strtokFile())) {
List<protocol_t> *q = new List<protocol_t> (urlParseProtocol(t));
*(Tail) = q;
/* explicit template instantiation required for some systems */
-template class ACLRequestHeaderStrategy<HDR_REFERER>
-
-;
+template class ACLRequestHeaderStrategy<HDR_REFERER>;
ACL::Prototype ACLReferer::RegistryProtoype(&ACLReferer::RegistryEntry_, "referer_regex");
int errcode;
int flags = REG_EXTENDED | REG_NOSUB;
- for (Tail = (relist **)curlist; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = (relist **)curlist; *Tail; Tail = &((*Tail)->next));
while ((t = ConfigParser::strtokFile())) {
if (strcmp(t, "-i") == 0) {
flags |= REG_ICASE;
/* explicit template instantiation required for some systems */
-template class ACLReplyHeaderStrategy<HDR_CONTENT_TYPE>
-
-;
+template class ACLReplyHeaderStrategy<HDR_CONTENT_TYPE>;
ACL::Prototype ACLReplyMIMEType::RegistryProtoype(&ACLReplyMIMEType::RegistryEntry_, "rep_mime_type");
/* explicit template instantiation required for some systems */
-template class ACLRequestHeaderStrategy<HDR_CONTENT_TYPE>
-
-;
+template class ACLRequestHeaderStrategy<HDR_CONTENT_TYPE>;
ACL::Prototype ACLRequestMIMEType::RegistryProtoype(&ACLRequestMIMEType::RegistryEntry_, "req_mime_type");
/* explicit template instantiation required for some systems */
-template class ACLStrategised<int>
-
-;
+template class ACLStrategised<int>;
ACL::Prototype ACLSslError::RegistryProtoype(&ACLSslError::RegistryEntry_, "ssl_error");
List<ssl_error_t> **Tail;
char *t = NULL;
- for (Tail = &values; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = &values; *Tail; Tail = &((*Tail)->next));
while ((t = strtokFile())) {
List<ssl_error_t> *q = new List<ssl_error_t>(sslParseErrorString(t));
*(Tail) = q;
/* explicit template instantiation required for some systems */
-template class ACLStrategised<HttpHeader*>
-
-;
+template class ACLStrategised<HttpHeader*>;
virtual bool valid() const {return true;}
- virtual ~ACLStrategy(){}}
-
-;
+ virtual ~ACLStrategy(){}
+};
#endif /* SQUID_ACLSTRATEGY_H */
ACLTimeData **Tail;
long weekbits = 0;
- for (Tail = &next; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = &next; *Tail; Tail = &((*Tail)->next));
ACLTimeData *q = NULL;
int h1, m1, h2, m2;
struct
{
-
-unsigned int case_insensitive:
- 1;
-
-unsigned int required:
- 1;
- }
-
- flags;
+ unsigned int case_insensitive:1;
+ unsigned int required:1;
+ } flags;
};
MEMPROXY_CLASS_INLINE(ACLUserData) /**DOCS_NOSEMI*/
#if USE_SSL
,ssluser(NULL)
#endif
- {
- ;
+ {;
}
IPAddress caddr;
{
/* lock for the request link */
- lock()
-
- ;
+ lock();
dlink_node *node = dlinkNodeNew();
dlinkAdd(request, node, &requests);
void addIp(IPAddress);
_SQUID_INLINE_ void addRequest(AuthUserRequest *);
- void lock()
-
- ;
+ void lock();
void unlock();
void addToNameCache();
struct
{
-
-unsigned int pw_req:
- 1;
-
-unsigned int atomic:
- 1;
- }
-
- flags;
+ unsigned int pw_req:1;
+ unsigned int atomic:1;
+ } flags;
CacheManagerAction *next;
};
{
debugs(77, 3, "DelayUserBucket::DelayUserBucket");
- authUser->lock()
-
- ;
+ authUser->lock();
}
DelayUserBucket::~DelayUserBucket()
aRequest);
if (x < 0) {
- ioCompleted()
- ;
+ ioCompleted();
errorOccured = true;
debugs(79, 1, "storeDiskdSend WRITE: " << xstrerror());
// IO->shm.put (shm_offset);
struct
{
-
-int attemptok:
- 1; /* the attempt branch process correctly */
-
-int exceptok:
- 1; /* likewise */
-
-int attemptfailed:
- 1; /* The attempt branch failed */
-
-int exceptfailed:
- 1; /* the except branch failed */
+ int attemptok:1; /* the attempt branch process correctly */
+ int exceptok:1; /* likewise */
+ int attemptfailed:1; /* The attempt branch failed */
+ int exceptfailed:1; /* the except branch failed */
}
flags;
{
// void *operator new (size_t byteCount);
// void operator delete (void *address);
- esiOtherwise(esiTreeParentPtr aParent) : esiSequence (aParent) {}}
-
-;
+ esiOtherwise(esiTreeParentPtr aParent) : esiSequence (aParent) {}
+};
CBDATA_CLASS_INIT(ESIContext);
{
// void *operator new (size_t byteCount);
// void operator delete (void *address);
- esiAttempt(esiTreeParentPtr aParent) : esiSequence (aParent) {}}
-
-;
-
+ esiAttempt(esiTreeParentPtr aParent) : esiSequence (aParent) {}
+};
#endif /* SQUID_ESIATTEMPT_H */
struct
{
-
-int passthrough:
- 1;
-
-int oktosend:
- 1;
-
-int finished:
- 1;
+ int passthrough:1;
+ int oktosend:1;
+ int finished:1;
/* an error has occured, send full body replies
* regardless. Note that we don't fail midstream
* because we buffer until we can not fail
*/
+ int error:1;
-int error:
- 1;
-
-int finishedtemplate:
- 1; /* we've read the entire template */
-
-int clientwantsdata:
- 1; /* we need to satisfy a read request */
+ int finishedtemplate:1; /* we've read the entire template */
+ int clientwantsdata:1; /* we need to satisfy a read request */
+ int kicked:1; /* note on reentering the kick routine */
+ int detached:1; /* our downstream has detached */
+ } flags;
-int kicked:
- 1; /* note on reentering the kick routine */
-
-int detached:
- 1; /* our downstream has detached */
- }
-
- flags;
err_type errorpage; /* if we error what page to use */
http_status errorstatus; /* if we error, what code to return */
char *errormessage; /* error to pass to error page */
ParserState();
void freeResources();
void popAll();
-
- int parsing:
- 1; /* libexpat is not reentrant on the same context */
+ int parsing:1; /* libexpat is not reentrant on the same context */
private:
bool inited_;
virtual void fail(ESIElement * source, char const *reason = NULL) {}
- virtual ~esiTreeParent(){}}
-
-;
+ virtual ~esiTreeParent(){}
+};
typedef RefCount<esiTreeParent> esiTreeParentPtr;
public:
// void *operator new (size_t byteCount);
// void operator delete (void *address);
- esiExcept(esiTreeParentPtr aParent) : esiSequence (aParent) {}}
-
-;
+ esiExcept(esiTreeParentPtr aParent) : esiSequence (aParent) {}
+};
#endif /* SQUID_ESIEXCEPT_H */
struct
{
-
-int onerrorcontinue:
- 1; /* on error return zero data */
-
-int failed:
- 1; /* Failed to process completely */
-
-int finished:
- 1; /* Finished getting subrequest data */
- }
-
- flags;
+ int onerrorcontinue:1; /* on error return zero data */
+ int failed:1; /* Failed to process completely */
+ int finished:1; /* Finished getting subrequest data */
+ } flags;
ESIStreamContext::Pointer src;
ESIStreamContext::Pointer alt;
ESISegment::Pointer srccontent;
struct
{
+ int donevars:1;
+ } flags;
-int donevars:
- 1;
- }
-
- flags;
ESIVarState *varState;
void finish();
struct
{
-
-int dovars:
- 1; /* for esiVar */
- }
-
- flags;
+ int dovars:1; /* for esiVar */
+ } flags;
void finish();
protected:
struct
{
-
-int language:
- 1;
-
-int cookie:
- 1;
-
-int host:
- 1;
-
-int referer:
- 1;
-
-int useragent:
- 1;
- }
-
- flags;
+ int language:1;
+ int cookie:1;
+ int host:1;
+ int referer:1;
+ int useragent:1;
+ } flags;
public:
{
prepareToRun();
- while (!runOnce())
-
- ;
+ while (!runOnce());
}
bool
SQUIDCEXTERN void httpHdrContRangePackInto(const HttpHdrContRange * crange, Packer * p);
/* inits with given spec */
SQUIDCEXTERN void httpHdrContRangeSet(HttpHdrContRange *, HttpHdrRangeSpec, int64_t);
-;
SQUIDCEXTERN void httpHeaderAddContRange(HttpHeader *, HttpHdrRangeSpec, int64_t);
size_t len;
static char delim[2][3] = {
{ '"', '?', 0},
- { '"', '\\', 0}};
+ { '"', '\\', 0} };
int quoted = 0;
assert(str && item && pos);
};
ICMPv4::ICMPv4() : ICMP()
-{
- ;
+{;
}
ICMPv4::~ICMPv4()
*/
mb_size_t capacity;
-unsigned stolen:
- 1; /* the buffer has been stolen for use by someone else */
+ unsigned stolen:1; /* the buffer has been stolen for use by someone else */
#if 0
-unsigned valid:
- 1; /* to be used for debugging only! */
+ unsigned valid:1; /* to be used for debugging only! */
#endif
};
void operator delete (void *);
virtual int bytesWanted (int minimum, int maximum) const {return max(minimum,maximum);}
- virtual void bytesIn(int qty) {}}
-
-;
+ virtual void bytesIn(int qty) {}
+};
#endif
#endif /* NULLDELAYID_H */
struct
{
-unsigned int needed:
- 1; /* there were requests for this digest */
-
-unsigned int usable:
- 1; /* can be used for lookups */
-
-unsigned int requested:
- 1; /* in process of receiving [fresh] digest */
- }
-
- flags;
+ unsigned int needed:1; /* there were requests for this digest */
+ unsigned int usable:1; /* can be used for lookups */
+ unsigned int requested:1; /* in process of receiving [fresh] digest */
+ } flags;
struct
{
time_t req_delay; /* last request response time */
time_t received; /* received the current copy of a digest */
time_t disabled; /* disabled for good */
- }
-
- times;
+ } times;
struct
{
{
int msgs;
kb_t kbytes;
- }
-
- sent, recv;
- }
-
- stats;
+ } sent, recv;
+ } stats;
private:
CBDATA_CLASS(PeerDigest);
char *name; /* visible name */
char *defaultsite; /* default web site */
-unsigned int transparent:
- 1; /* transparent proxy */
+ unsigned int transparent:1; /* transparent proxy */
-unsigned int accel:
- 1; /* HTTP accelerator */
+ unsigned int accel:1; /* HTTP accelerator */
-unsigned int vhost:
- 1; /* uses host header */
+ unsigned int vhost:1; /* uses host header */
-unsigned int sslBump:
- 1; /* intercepts CONNECT requests */
+ unsigned int sslBump:1; /* intercepts CONNECT requests */
int vport; /* virtual port support, -1 for dynamic, >0 static*/
int disable_pmtu_discovery;
#if LINUX_TPROXY
-unsigned int tproxy:
- 1; /* spoof client ip using tproxy */
+ unsigned int tproxy:1; /* spoof client ip using tproxy */
#endif
struct {
struct
{
-
-unsigned int disk_io_pending:
- 1;
-
-unsigned int store_copying:
- 1;
-
-unsigned int copy_event_pending:
- 1;
- }
-
- flags;
+ unsigned int disk_io_pending:1;
+ unsigned int store_copying:1;
+ unsigned int copy_event_pending:1;
+ } flags;
#if DELAY_POOLS
DelayId delayId;
};
class StoreHashIndexEntry : public StoreEntry
-{}
-
-;
+{};
class StoreSearchHashIndex : public StoreSearch
{
struct
{
-
-unsigned error:
- 1;
- }
-
- flags;
+ unsigned error:1;
+ } flags;
size_t length;
int64_t offset;
char *data;
struct
{
-
-unsigned int closing:
- 1; /* debugging aid */
+ unsigned int closing:1; /* debugging aid */
}
flags;
struct Flags
{
Flags() : selected(0), read_only(0){}
-
-unsigned int selected:
- 1;
-
-unsigned int read_only:
- 1;
+ unsigned int selected:1;
+ unsigned int read_only:1;
}
flags;
} data;
unsigned char width;
unsigned char precision;
-
enum log_quote quote;
-
-unsigned int left:
- 1;
-
-unsigned int space:
- 1;
-
-unsigned int zero:
- 1;
+ unsigned int left:1;
+ unsigned int space:1;
+ unsigned int zero:1;
int divisor;
logformat_token *next; /* todo: move from linked list to array */
};
A->cfgline = xstrdup(config_input_line);
/* Append to the end of this list */
- for (B = *head, T = head; B; T = &B->next, B = B->next)
-
- ;
+ for (B = *head, T = head; B; T = &B->next, B = B->next);
*T = A;
/* We lock _acl_access structures in ACLChecklist::check() */
FwdState::fwdStart(-1, e, asState->request);
} else {
- e->lock()
-
- ;
+ e->lock();
asState->sc = storeClientListAdd(e, asState);
}
} else {
debugs(53, 3, "asnAddNet: Warning: Found a network with multiple AS numbers!");
- for (Tail = &asinfo->as_number; *Tail; Tail = &(*Tail)->next)
- ;
+ for (Tail = &asinfo->as_number; *Tail; Tail = &(*Tail)->next);
q = new List<int> (as_number);
*(Tail) = q;
List<int> *q = NULL;
char *t = NULL;
- for (Tail = curlist; *Tail; Tail = &((*Tail)->next))
-
- ;
+ for (Tail = curlist; *Tail; Tail = &((*Tail)->next));
while ((t = strtokFile())) {
q = new List<int> (atoi(t));
*(Tail) = q;
/* explicit template instantiation required for some systems */
-template class ACLStrategised<IPAddress>
-
-;
+template class ACLStrategised<IPAddress>;
ACL::Prototype ACLASN::SourceRegistryProtoype(&ACLASN::SourceRegistryEntry_, "src_as");
assert (!authUser());
user(aUser);
- user()->lock()
-
- ;
+ user()->lock();
}
AuthDigestUserRequest::CredentialsState
struct
{
-
-unsigned int authinfo_sent:
- 1;
-
+ unsigned int authinfo_sent:1;
unsigned int invalid_password:1;
-
-unsigned int helper_queried:
- 1;
- }
-
- flags;
+ unsigned int helper_queried:1;
+ } flags;
digest_nonce_h *nonce;
private:
struct
{
-
-unsigned int valid:
- 1;
-
-unsigned int incache:
- 1;
- }
-
- flags;
+ unsigned int valid:1;
+ unsigned int incache:1;
+ } flags;
};
/* configuration runtime data */
l->domain = xstrdup(domain);
- for (L = &(p->peer_domain); *L; L = &((*L)->next))
-
- ;
+ for (L = &(p->peer_domain); *L; L = &((*L)->next));
*L = l;
}
}
l->type = parseNeighborType(type);
l->domain = xstrdup(domain);
- for (L = &(p->typelist); *L; L = &((*L)->next))
-
- ;
+ for (L = &(p->typelist); *L; L = &((*L)->next));
*L = l;
}
}
a->flags.pw_req = pw_req_flag;
a->flags.atomic = atomic;
- for (A = &ActionTable; *A; A = &(*A)->next)
-
- ;
+ for (A = &ActionTable; *A; A = &(*A)->next);
*A = a;
debugs(16, 3, "CacheManager::registerAction: registered " << action);
mgr->entry = entry;
- entry->lock()
-
- ;
+ entry->lock();
entry->expires = squid_curtime;
debugs(16, 5, "CACHEMGR: " << fd_table[fd].ipaddr << " requesting '" << mgr->action << "'");
*/
void
cbdata::operator delete(void *where, void *where2)
-{
- ;
+{;
}
long
ClientSocketContext::Pointer *S;
for (S = (ClientSocketContext::Pointer *) & currentobject; S->getRaw();
- S = &(*S)->next)
-
- ;
+ S = &(*S)->next);
*S = context;
++nrequests;
ClientSocketContext::Pointer *T;
for (T = (ClientSocketContext::Pointer *) ¤tobject;
- T->getRaw(); T = &(*T)->next, ++result)
-
- ;
+ T->getRaw(); T = &(*T)->next, ++result);
return result;
}
assert(chr == NULL);
/* add to the client request queue */
- for (H = &chr; *H; H = &(*H)->next)
-
- ;
+ for (H = &chr; *H; H = &(*H)->next);
*H = http;
clientStreamRead(http->client_stream.tail->data, http, 0,
/* Swap in the metadata */
http->storeEntry(entry);
- http->storeEntry()->lock()
-
- ;
+ http->storeEntry()->lock();
http->storeEntry()->createMemObject(http->uri, http->log_uri);
http->storeEntry()->mem_obj->method = http->request->method;
/* someone found the object in the cache for us */
StoreIOBuffer tempBuffer;
- http->storeEntry()->lock()
-
- ;
+ http->storeEntry()->lock();
if (http->storeEntry()->mem_obj == NULL) {
/*
loggingEntry_ = newEntry;
if (loggingEntry_)
- loggingEntry_->lock()
-
- ;
+ loggingEntry_->lock();
}
/*
int64_t offset;
int64_t size;
size_t headers_sz;
- }
+ } out;
- out;
HttpHdrRangeIter range_iter; /* data for iterating thru range specs */
size_t req_sz; /* raw request size on input, not current request size */
log_type logType;
struct
{
-
-unsigned int accel:
- 1;
-
-unsigned int transparent:
- 1;
-
-unsigned int internal:
- 1;
-
-unsigned int done_copying:
- 1;
-
-unsigned int purging:
- 1;
- }
-
- flags;
+ unsigned int accel:1;
+ unsigned int transparent:1;
+ unsigned int internal:1;
+ unsigned int done_copying:1;
+ unsigned int purging:1;
+ } flags;
struct
{
http_status status;
char *location;
- }
+ } redirect;
- redirect;
dlink_node active;
dlink_list client_stream;
int mRangeCLen();
statCounter.select_time += (current_dtime - start);
return COMM_OK;
- } while (timeout > current_dtime)
-
- ;
+ } while (timeout > current_dtime);
debugs(5, 8, "comm_select: time out: " << squid_curtime);
return COMM_TIMEOUT;
statCounter.select_time += (current_dtime - start);
return COMM_OK;
- } while (timeout > current_dtime)
-
- ;
+ } while (timeout > current_dtime);
debugs(5, 8, "comm_select: time out: " << squid_curtime);
return COMM_TIMEOUT;
} else {
s = atoi(arg);
- while (*arg && *arg++ != ',')
-
- ;
+ while (*arg && *arg++ != ',');
}
l = atoi(arg);
struct
{
-
-unsigned int flag_cbdata:
- 1;
- }
-
- flags;
+ unsigned int flag_cbdata:1;
+ } flags;
struct
{
wordlist *server_msg;
char *request;
char *reply;
- }
+ } ftp;
- ftp;
char *request_hdrs;
char *err_msg; /* Preformatted error message from the cache */
request = HTTPMSGLOCK(r);
start_t = squid_curtime;
- e->lock()
-
- ;
+ e->lock();
EBIT_SET(e->flags, ENTRY_FWD_HDR_WAIT);
}
FwdServer **T, *T2 = NULL;
servers = fs->next;
- for (T = &servers; *T; T2 = *T, T = &(*T)->next)
-
- ;
+ for (T = &servers; *T; T2 = *T, T = &(*T)->next);
if (T2 && T2->_peer) {
/* cycle */
*T = fs;
struct
{
-
-unsigned int dont_retry:
- 1;
-
-unsigned int ftp_pasv_failed:
- 1;
-
-unsigned int forward_completed:1;
+ unsigned int dont_retry:1;
+ unsigned int ftp_pasv_failed:1;
+ unsigned int forward_completed:1;
}
flags;
struct
{
-
-unsigned int negcached:
- 1;
-
-unsigned int fromhosts:
- 1;
+ unsigned int negcached:1;
+ unsigned int fromhosts:1;
}
flags;
#if USE_DNSSERVERS
fqdncacheParse(f, reply);
- ;
#else
fqdncacheParse(f, answers, na, error_message);
struct
{
-
-unsigned int reading:
- 1;
-
-unsigned int writing:
- 1;
- }
-
- flags;
+ unsigned int reading:1;
+ unsigned int writing:1;
+ } flags;
CossMemBuf *locked_membuf;
off_t st_size;
struct
{
-
-unsigned int clean:
- 1;
- }
-
- flags;
+ unsigned int clean:1;
+ } flags;
struct _store_rebuild_data counts;
};
while (strlen(pathtmp) && pathtmp[strlen(pathtmp) - 1] == '.')
pathtmp[strlen(pathtmp) - 1] = '\0';
- for (pathtmp2 = pathtmp; *pathtmp2 == '.'; pathtmp2++)
-
- ;
+ for (pathtmp2 = pathtmp; *pathtmp2 == '.'; pathtmp2++);
snprintf(path, SQUID_MAXPATHLEN - 64, Config.Log.swap, pathtmp2);
if (strncmp(path, Config.Log.swap, SQUID_MAXPATHLEN - 64) == 0) {
while (strlen(pathtmp) && pathtmp[strlen(pathtmp) - 1] == '.')
pathtmp[strlen(pathtmp) - 1] = '\0';
- for (pathtmp2 = pathtmp; *pathtmp2 == '.'; pathtmp2++)
-
- ;
+ for (pathtmp2 = pathtmp; *pathtmp2 == '.'; pathtmp2++);
snprintf(lpath, SQUID_MAXPATHLEN - 64, Config.Log.swap, pathtmp2);
if (strncmp(lpath, Config.Log.swap, SQUID_MAXPATHLEN - 64) == 0) {
struct
{
-
-unsigned int need_to_validate:
- 1;
-
-unsigned int clean:
- 1;
-
-unsigned int init:
- 1;
- }
-
- flags;
+ unsigned int need_to_validate:1;
+ unsigned int clean:1;
+ unsigned int init:1;
+ } flags;
int in_dir;
int done;
int fn;
const char *p;
snprintf(html, 8192, "%s\n", line);
- for (p = line; *p && xisspace(*p); p++)
-
- ;
+ for (p = line; *p && xisspace(*p); p++);
if (*p && !xisspace(*p))
flags.listformat_unknown = 1;
}
/* Move the last line of the reply message to ctrl.last_reply */
- for (W = &ctrl.message; (*W)->next; W = &(*W)->next)
-
- ;
+ for (W = &ctrl.message; (*W)->next; W = &(*W)->next);
safe_free(ctrl.last_reply);
ctrl.last_reply = xstrdup((*W)->key);
gopherState = cbdataAlloc(GopherStateData);
gopherState->buf = (char *)memAllocate(MEM_4K_BUF);
- entry->lock()
-
- ;
+ entry->lock();
gopherState->entry = entry;
gopherState->fwd = fwd;
struct _helper_flags
{
-
-unsigned int writing:
- 1;
-
-unsigned int closing:
- 1;
-
-unsigned int shutdown:
- 1;
- }
-
- flags;
+ unsigned int writing:1;
+ unsigned int closing:1;
+ unsigned int shutdown:1;
+ } flags;
struct
{
int uses;
unsigned int pending;
- }
-
- stats;
+ } stats;
void *hIpc;
};
struct _helper_stateful_flags
{
-
-unsigned int busy:
- 1;
-
-unsigned int closing:
- 1;
-
-unsigned int shutdown:
- 1;
+ unsigned int busy:1;
+ unsigned int closing:1;
+ unsigned int shutdown:1;
stateful_helper_reserve_t reserved;
- }
-
- flags;
+ } flags;
struct
{
int releases;
int deferbyfunc;
int deferbycb;
- }
-
- stats;
+ } stats;
int deferred_requests; /* current number of deferred requests */
void *data; /* State data used by the calling routines */
void *hIpc;
struct _htcpDataHeaderSquid
{
u_int16_t length;
-#if !WORDS_BIGENDIAN
-
-unsigned int opcode:
- 4;
-unsigned int response:
- 4;
+#if !WORDS_BIGENDIAN
+ unsigned int opcode:4;
+ unsigned int response:4;
#else
-
-unsigned int response:
- 4;
-
-unsigned int opcode:
- 4;
+ unsigned int response:4;
+ unsigned int opcode:4;
#endif
-#if !WORDS_BIGENDIAN
-unsigned int reserved:
- 6;
-
-unsigned int F1:
- 1;
-
-unsigned int RR:
- 1;
+#if !WORDS_BIGENDIAN
+ unsigned int reserved:6;
+ unsigned int F1:1;
+ unsigned int RR:1;
#else
-
-unsigned int RR:
- 1;
-
-unsigned int F1:
- 1;
-
-unsigned int reserved:
- 6;
+ unsigned int RR:1;
+ unsigned int F1:1;
+ unsigned int reserved:6;
#endif
u_int32_t msg_id;
struct _htcpDataHeader
{
u_int16_t length;
-#if WORDS_BIGENDIAN
-
-u_int8_t opcode:
- 4;
-u_int8_t response:
- 4;
+#if WORDS_BIGENDIAN
+ u_int8_t opcode:4;
+ u_int8_t response:4;
#else
-
-u_int8_t response:
- 4;
-
-u_int8_t opcode:
- 4;
+ u_int8_t response:4;
+ u_int8_t opcode:4;
#endif
-#if WORDS_BIGENDIAN
-u_int8_t reserved:
- 6;
-
-u_int8_t F1:
- 1;
-
-u_int8_t RR:
- 1;
+#if WORDS_BIGENDIAN
+ u_int8_t reserved:6;
+ u_int8_t F1:1;
+ u_int8_t RR:1;
#else
-
-u_int8_t RR:
- 1;
-
-u_int8_t F1:
- 1;
-
-u_int8_t reserved:
- 6;
+ u_int8_t RR:1;
+ u_int8_t F1:1;
+ u_int8_t reserved:6;
#endif
u_int32_t msg_id;
if (strstr(buf, "USERID")) {
if ((ident = strrchr(buf, ':'))) {
- while (xisspace(*++ident))
-
- ;
+ while (xisspace(*++ident));
identCallback(state, ident);
}
}
c->callback = callback;
c->callback_data = cbdataReference(callback_data);
- for (C = &state->clients; *C; C = &(*C)->next)
-
- ;
+ for (C = &state->clients; *C; C = &(*C)->next);
*C = c;
}
struct
{
-
-unsigned int negcached:
- 1;
-
-unsigned int fromhosts:
- 1;
+ unsigned int negcached:1;
+ unsigned int fromhosts:1;
}
flags;
StoreIOBuffer nodeBuffer;
/* Private */
char data[SM_PAGE_SIZE];
-
-unsigned int write_pending:
- 1;
+ unsigned int write_pending:1;
};
MEMPROXY_CLASS_INLINE(mem_node) /**DOCS_NOSEMI*/
char *content_encoding;
char transfer_mode;
-unsigned int view_option:
- 1;
+ unsigned int view_option:1;
+ unsigned int download_option:1;
-unsigned int download_option:
- 1;
mimeEntry *next;
MimeIcon theIcon;
};
if (old_e) {
debugs(72, 5, "peerDigestRequest: found old entry");
- old_e->lock()
-
- ;
+ old_e->lock();
old_e->createMemObject(url, url);
fetch->old_sc = storeClientListAdd(old_e, fetch);
if (entry->locked()) {
- entry->lock()
-
- ;
+ entry->lock();
linklistPush(&heap_walker->locked_entries, entry);
goto try_again;
state->sentry = sentry;
state->filter = filter;
- sentry->lock()
-
- ;
+ sentry->lock();
state->theSearch = Store::Root().search(NULL, NULL);
eventAdd("statObjects", statObjects, state, 0.0, 1);
/*
* we have (part of) what they want
*/
- size_t copy_sz = XMIN(copyInto.length, body_sz)
- ;
+ size_t copy_sz = XMIN(copyInto.length, body_sz);
debugs(90, 3, "storeClientReadHeader: copying " << copy_sz << " bytes of body");
xmemmove(copyInto.data, copyInto.data + mem->swap_hdr_sz, copy_sz);
/* Don't lock until after create, or the replacement
* code might get confused */
- e->lock()
-
- ;
+ e->lock();
/* Pick up the file number if it was assigned immediately */
e->swap_filen = mem->swapout.sio->swap_filen;
*/
int highWaterMark;
int lowWaterMark;
- }
-
- Swap;
+ } Swap;
size_t memMaxSize;
struct
int64_t min;
int pct;
int64_t max;
- }
-
- quickAbort;
+ } quickAbort;
int64_t readAheadGap;
RemovalPolicySettings *replPolicy;
RemovalPolicySettings *memPolicy;
time_t idns_query;
#endif
- }
-
- Timeout;
+ } Timeout;
size_t maxRequestHeaderSize;
int64_t maxRequestBodySize;
size_t maxReplyHeaderSize;
u_short snmp;
#endif
-
- }
-
- Port;
+ } Port;
struct
{
https_port_list *https;
#endif
- }
-
- Sockaddr;
+ } Sockaddr;
#if SQUID_SNMP
struct
{
char *configFile;
char *agentInfo;
- }
-
- Snmp;
+ } Snmp;
#endif
#if USE_WCCP
IPAddress address;
int version;
- }
-
- Wccp;
+ } Wccp;
#endif
#if USE_WCCPv2
struct _http_state_flags
{
-
-unsigned int proxying:
- 1;
-
-unsigned int keepalive:
- 1;
-
-unsigned int only_if_cached:
- 1;
-
-unsigned int headers_parsed:
- 1;
-
-unsigned int front_end_https:
- 2;
-
-unsigned int originpeer:
- 1;
-
-unsigned int keepalive_broken:
- 1;
-
-unsigned int abuse_detected:
- 1;
-
-unsigned int request_sent:
- 1;
-
-unsigned int do_next_read:
- 1;
-
-unsigned int consume_body_data:
- 1;
-
-unsigned int chunked:1;
+ unsigned int proxying:1;
+ unsigned int keepalive:1;
+ unsigned int only_if_cached:1;
+ unsigned int headers_parsed:1;
+ unsigned int front_end_https:2;
+ unsigned int originpeer:1;
+ unsigned int keepalive_broken:1;
+ unsigned int abuse_detected:1;
+ unsigned int request_sent:1;
+ unsigned int do_next_read:1;
+ unsigned int consume_body_data:1;
+ unsigned int chunked:1;
};
struct _ipcache_addrs
struct
{
-
-unsigned int proxy_only:
- 1;
-
-unsigned int no_query:
- 1;
-
-unsigned int background_ping:
- 1;
-
-unsigned int no_digest:
- 1;
-
-unsigned int default_parent:
- 1;
-
-unsigned int roundrobin:
- 1;
-
-unsigned int weighted_roundrobin:
- 1;
-
-unsigned int mcast_responder:
- 1;
-
-unsigned int closest_only:
- 1;
+ unsigned int proxy_only:1;
+ unsigned int no_query:1;
+ unsigned int background_ping:1;
+ unsigned int no_digest:1;
+ unsigned int default_parent:1;
+ unsigned int roundrobin:1;
+ unsigned int weighted_roundrobin:1;
+ unsigned int mcast_responder:1;
+ unsigned int closest_only:1;
#if USE_HTCP
-
-unsigned int htcp:
- 1;
-
-unsigned int htcp_oldsquid:
- 1;
+ unsigned int htcp:1;
+ unsigned int htcp_oldsquid:1;
#endif
-
-unsigned int no_netdb_exchange:
- 1;
+ unsigned int no_netdb_exchange:1;
#if DELAY_POOLS
-
-unsigned int no_delay:
- 1;
+ unsigned int no_delay:1;
#endif
-
-unsigned int allow_miss:
- 1;
+ unsigned int allow_miss:1;
#if USE_CARP
-
-unsigned int carp:
- 1;
+ unsigned int carp:1;
#endif
+ unsigned int originserver:1;
+ } options;
-unsigned int originserver:
- 1;
- }
-
- options;
int weight;
int basetime;
struct
{
-
-unsigned int count_event_pending:
- 1;
-
-unsigned int counting:
- 1;
- }
-
- flags;
- }
-
- mcast;
+ unsigned int count_event_pending:1;
+ unsigned int counting:1;
+ } flags;
+ } mcast;
#if USE_CACHE_DIGESTS
PeerDigest *digest;
#if LINUX_TPROXY
tproxy = 0;
#endif
-
}
-unsigned int range:
- 1;
-
-unsigned int nocache:
- 1;
-
-unsigned int ims:
- 1;
-
-unsigned int auth:
- 1;
-
-unsigned int cachable:
- 1;
-
-unsigned int hierarchical:
- 1;
-
-unsigned int loopdetect:
- 1;
-
-unsigned int proxy_keepalive:
- 1;
-
-unsigned int proxying:
- 1; /* this should be killed, also in httpstateflags */
-
-unsigned int refresh:
- 1;
-
-unsigned int redirected:
- 1;
-
-unsigned int need_validation:
- 1;
+ unsigned int range:1;
+ unsigned int nocache:1;
+ unsigned int ims:1;
+ unsigned int auth:1;
+ unsigned int cachable:1;
+ unsigned int hierarchical:1;
+ unsigned int loopdetect:1;
+ unsigned int proxy_keepalive:1;
+ unsigned int proxying:1; /* this should be killed, also in httpstateflags */
+ unsigned int refresh:1;
+ unsigned int redirected:1;
+ unsigned int need_validation:1;
#if HTTP_VIOLATIONS
-
-unsigned int nocache_hack:
- 1; /* for changing/ignoring no-cache requests */
+ unsigned int nocache_hack:1; /* for changing/ignoring no-cache requests */
#endif
-
-unsigned int accelerated:
- 1;
-
-unsigned int transparent:
- 1;
-
+ unsigned int accelerated:1;
+ unsigned int transparent:1;
#if LINUX_TPROXY
-unsigned int tproxy:
- 1; /* spoof client ip using tproxy */
+ unsigned int tproxy:1; /* spoof client ip using tproxy */
#endif
-unsigned int internal:
- 1;
-
-unsigned int internalclient:
- 1;
-
-unsigned int must_keepalive:
- 1;
+ unsigned int internal:1;
+ unsigned int internalclient:1;
+ unsigned int must_keepalive:1;
// When adding new flags, please update cloneAdaptationImmune() as needed.
private:
-unsigned int reset_tcp:
- 1;
-
-unsigned int destinationIPLookedUp_:
- 1;
+ unsigned int reset_tcp:1;
+ unsigned int destinationIPLookedUp_:1;
};
struct _link_list
struct
{
-
-unsigned int icase:
- 1;
-
-unsigned int refresh_ims:
- 1;
+ unsigned int icase:1;
+ unsigned int refresh_ims:1;
#if HTTP_VIOLATIONS
-
-unsigned int override_expire:
- 1;
-
-unsigned int override_lastmod:
- 1;
-
-unsigned int reload_into_ims:
- 1;
-
-unsigned int ignore_reload:
- 1;
-
-unsigned int ignore_no_cache:
- 1;
-
-unsigned int ignore_no_store:
- 1;
-
-unsigned int ignore_private:
- 1;
-
-unsigned int ignore_auth:
- 1;
+ unsigned int override_expire:1;
+ unsigned int override_lastmod:1;
+ unsigned int reload_into_ims:1;
+ unsigned int ignore_reload:1;
+ unsigned int ignore_no_cache:1;
+ unsigned int ignore_no_store:1;
+ unsigned int ignore_private:1;
+ unsigned int ignore_auth:1;
#endif
-
- }
-
- flags;
+ } flags;
};
/*
StatHist nh_svc_time;
StatHist hit_svc_time;
StatHist all_svc_time;
- }
-
- client_http;
+ } client_http;
struct
{
int errors;
kb_t kbytes_in;
kb_t kbytes_out;
- }
-
- all , http, ftp, other;
- }
-
- server;
+ } all , http, ftp, other;
+ } server;
struct
{
{
int pkts_sent;
int pkts_recv;
- }
-
- htcp;
+ } htcp;
struct
{
int requests;
- }
-
- unlink;
+ } unlink;
struct
{
StatHist svc_time;
- }
-
- dns;
+ } dns;
struct
{
#endif
StatHist on_xition_count;
- }
-
- cd;
+ } cd;
struct
{
int times_used;
- }
-
- netdb;
+ } netdb;
int page_faults;
int select_loops;
int select_fds;
struct
{
-
struct
{
int opens;
int writes;
int seeks;
int unlinks;
- }
-
- disk;
+ } disk;
struct
{
int writes;
int recvfroms;
int sendtos;
- }
-
- sock;
+ } sock;
int selects;
- }
-
- syscalls;
+ } syscalls;
int aborted_requests;
struct
int files_cleaned;
int outs;
int ins;
- }
-
- swap;
+ } swap;
};
/* per header statistics */
kb_t kbytes_in;
kb_t kbytes_out;
kb_t hit_kbytes_out;
- }
-
- Http, Icp;
+ } Http, Icp;
struct
{
time_t time;
int n_req;
int n_denied;
- }
-
- cutoff;
+ } cutoff;
int n_established; /* number of current established connections */
time_t last_seen;
};
{
unsigned int fatal;
unsigned int syslog;
- }
-
- flags;
+ } flags;
int syslog_priority;
};
params[]={ {"digest", digest_parms, 2},
{"basic", basic_parms, 2},
{"ntlm", ntlm_parms, 1},
- {"negotiate", negotiate_parms, 1}};
+ {"negotiate", negotiate_parms, 1}
+ };
for (unsigned scheme=0; scheme < 4; scheme++)
setup_scheme(getConfig(params[scheme].name), params[scheme].params, params[scheme].paramlength);
"\n"
"Operation \tNext Execution \tWeight\tCallback Valid?\n"
"test event \t0.000 sec\t 0\t N/A\n"
- "test event2 \t0.000 sec\t 0\t N/A\n"
- ;
+ "test event2 \t0.000 sec\t 0\t N/A\n";
scheduler.schedule("last event", CalledEvent::Handler, &event, 0, 0, false);
}
- while (pid > 0 || (pid < 0 && errno == EINTR))
-
- ;
+ while (pid > 0 || (pid < 0 && errno == EINTR));
signal(sig, sig_child);
#endif
struct
{
-
-unsigned int force_menu:
- 1;
- }
-
- flags;
+ unsigned int force_menu:1;
+ } flags;
char reqbuf[URN_REQBUF_SZ];
int reqofs;
entry = e;
request = HTTPMSGLOCK(r);
- entry->lock()
-
- ;
+ entry->lock();
setUriResFromRequest(r);
if (urlres_r == NULL)
FwdState::fwdStart(-1, urlres_e, urlres_r);
} else {
- urlres_e->lock()
-
- ;
+ urlres_e->lock();
sc = storeClientListAdd(urlres_e, this);
}
uint32_t change_num;
char *wccp2_identity_info_ptr;
- ;
struct wccp2_security_md5_t *security_info;
p->fwd = fwd;
p->dataWritten = false;
- p->entry->lock()
-
- ;
+ p->entry->lock();
comm_add_close_handler(fd, whoisClose, p);
l = p->request->urlpath.size() + 3;
if (strncasecmp(sline, "HTTP/", 5) || !sp)
return -1;
- while (xisspace(*++sp))
-
- ;
+ while (xisspace(*++sp));
if (!xisdigit(*sp))
return -1;