ENTRY_BAD_LENGTH set. We should release the
bad entry to prevent secondary clients jumping on.
- Changed MIB to prevent parse warnings at startup.
+ - Fixed a forwarding loop bug. Even though we were detecting
+ a loop, it was not being broken.
+ - Try to prevent sibling forwarding loops by NOT forwarding a
+ request to a sibling if we have a stale copy of the object.
+ Validation requests should only be sent to parents (or
+ direct).
+ - Fixed ncsa_auth hash bugs when re-reading password file.
+ - Changed clientHierarchical() so that by default SSL/CONNECT
+ requests do NOT go to neighbor caches.
Changes to squid-1.2.beta25 (September 21, 1998):
/*
- * $Id: StatHist.cc,v 1.13 1998/10/03 03:56:51 wessels Exp $
+ * $Id: StatHist.cc,v 1.14 1998/10/08 02:40:04 wessels Exp $
*
* DEBUG: section 62 Generic Histogram
* AUTHOR: Duane Wessels
static double
Log(double x)
{
- return log(x + 1);
+ assert((x + 1.0) >= 0.0);
+ return log(x + 1.0);
}
static double
Exp(double x)
{
- return exp(x) - 1;
+ return exp(x) - 1.0;
}
void
statHistLogInit(StatHist * H, int capacity, double min, double max)
/*
- * $Id: client_side.cc,v 1.406 1998/10/03 03:56:52 wessels Exp $
+ * $Id: client_side.cc,v 1.407 1998/10/08 02:40:05 wessels Exp $
*
* DEBUG: section 33 Client-side Routines
* AUTHOR: Duane Wessels
return 1;
if (method != METHOD_GET)
return 0;
+ if (method != METHOD_CONNECT)
+ return 0;
/* scan hierarchy_stoplist */
for (p = Config.hierarchy_stoplist; p; p = p->next)
if (strstr(url, p->key))
/*
* We hold a stale copy; it needs to be validated
*/
+ /*
+ * The 'need_validation' flag is used to prevent forwarding
+ * loops between siblings. If our copy of the object is stale,
+ * then we should probably only use parents for the validation
+ * request. Otherwise two siblings could generate a loop if
+ * both have a stale version of the object.
+ */
+ r->flags.need_validation = 1;
if (e->lastmod < 0) {
/*
* Previous reply didn't have a Last-Modified header,
/*
- * $Id: comm.cc,v 1.287 1998/10/01 22:28:26 wessels Exp $
+ * $Id: comm.cc,v 1.288 1998/10/08 02:40:06 wessels Exp $
*
* DEBUG: section 5 Socket Functions
* AUTHOR: Harvest Derived
fde *F = &fd_table[sock];
int x;
int err = 0;
- int errlen;
+ socklen_t errlen;
assert(ntohs(address->sin_port) != 0);
/* Establish connection. */
errno = 0;
/*
- * $Id: neighbors.cc,v 1.256 1998/10/03 03:56:54 wessels Exp $
+ * $Id: neighbors.cc,v 1.257 1998/10/08 02:40:07 wessels Exp $
*
* DEBUG: section 15 Neighbor Routines
* AUTHOR: Harvest Derived
int do_ping = 1;
aclCheck_t checklist;
assert(request != NULL);
- if (request->flags.nocache)
- if (neighborType(p, request) == PEER_SIBLING)
+ if (neighborType(p, request) == PEER_SIBLING) {
+ if (request->flags.nocache)
return 0;
- if (request->flags.refresh)
- if (neighborType(p, request) == PEER_SIBLING)
+ if (request->flags.refresh)
return 0;
+ if (request->flags.loopdetect)
+ return 0;
+ if (request->flags.need_validation)
+ return 0;
+ }
if (p->pinglist == NULL && p->access == NULL)
return do_ping;
do_ping = 0;
if (p->digest.flags.disabled) {
debug(15, 5) ("peerDigestLookup: Disabled!\n");
return LOOKUP_NONE;
- } else if (!peerAllowedToUse(p, request)) {
- debug(15, 5) ("peerDigestLookup: !peerAllowedToUse()\n");
+ } else if (!peerHTTPOkay(p, request)) {
+ debug(15, 5) ("peerDigestLookup: !peerHTTPOkay()\n");
return LOOKUP_NONE;
} else if (p->digest.flags.usable) {
debug(15, 5) ("peerDigestLookup: Usable!\n");
-
-
/*
- * $Id: structs.h,v 1.237 1998/09/30 02:53:19 wessels Exp $
+ * $Id: structs.h,v 1.238 1998/10/08 02:40:09 wessels Exp $
*
*
* SQUID Internet Object Cache http://squid.nlanr.net/Squid/
unsigned int refresh:1;
unsigned int used_proxy_auth:1;
unsigned int redirected:1;
+ unsigned int need_validation:1;
#if HTTP_VIOLATIONS
unsigned int nocache_hack:1; /* for changing/ignoring no-cache requests */
#endif