/*
- * $Id: client_side.cc,v 1.267 1998/04/09 00:17:56 wessels Exp $
+ * $Id: client_side.cc,v 1.268 1998/04/09 02:25:20 wessels Exp $
*
* DEBUG: section 33 Client-side Routines
* AUTHOR: Duane Wessels
StoreEntry *e;
if ((e = http->entry = storeGet(key)) == NULL) {
/* this object isn't in the cache */
+ if (http->internal)
+ debug_trap("TCP_MISS for internal object");
return LOG_TCP_MISS;
} else if (EBIT_TEST(e->flag, ENTRY_SPECIAL)) {
/* ideally, special entries should be processed later,
/*
- * $Id: ipcache.cc,v 1.176 1998/04/03 06:27:05 wessels Exp $
+ * $Id: ipcache.cc,v 1.177 1998/04/09 02:25:22 wessels Exp $
*
* DEBUG: section 14 IP Cache
* AUTHOR: Harvest Derived
for (k = 0; k < (int) i->addrs.count; k++)
storeAppendPrintf(sentry, " %15s-%3s", inet_ntoa(i->addrs.in_addrs[k]),
i->addrs.bad_mask[k] ? "BAD" : "OK ");
+ if (i->addrs.count > 1 && k == i->addrs.cur)
+ storeAppendPrintf(sentry, ",CUR"),
storeAppendPrintf(sentry, "\n");
}
extern void urlInitialize(void);
extern request_t *urlParse(method_t, char *);
extern char *urlCanonical(const request_t *, char *);
-extern char *urlRInternal(const char *host, int port, const char *dir, const char *name);
+extern char *urlRInternal(const char *host, u_short port, const char *dir, const char *name);
extern char *urlInternal(const char *dir, const char *name);
extern request_t *requestLink(request_t *);
extern void requestUnlink(request_t *);
/*
- * $Id: url.cc,v 1.86 1998/04/06 05:43:27 rousskov Exp $
+ * $Id: url.cc,v 1.87 1998/04/09 02:25:24 wessels Exp $
*
* DEBUG: section 23 URL Parsing
* AUTHOR: Duane Wessels
/* makes internal url with a given host and port (remote internal url) */
char *
-urlRInternal(const char *host, int port, const char *dir, const char *name)
+urlRInternal(const char *host, u_short port, const char *dir, const char *name)
{
LOCAL_ARRAY(char, buf, MAX_URL);
+ static char lc_host[SQUIDHOSTNAMELEN];
assert(host && port && name);
+ xstrncpy(lc_host, host, SQUIDHOSTNAMELEN);
+ Tolower(lc_host);
if (!dir || !*dir)
- snprintf(buf, MAX_URL, "http://%s:%d/squid-internal/%s", host, port, name);
+ snprintf(buf, MAX_URL, "http://%s:%d/squid-internal/%s", lc_host, port, name);
else
- snprintf(buf, MAX_URL, "http://%s:%d/squid-internal/%s/%s", host, port, dir, name);
+ snprintf(buf, MAX_URL, "http://%s:%d/squid-internal/%s/%s", lc_host, port, dir, name);
return buf;
}
char *
urlInternal(const char *dir, const char *name)
{
- static char host[SQUIDHOSTNAMELEN];
- xstrncpy(host, getMyHostname(), SQUIDHOSTNAMELEN);
- Tolower(host);
- return urlRInternal(host, Config.Port.http->i, dir, name);
+ return urlRInternal(getMyHostname(), Config.Port.http->i, dir, name);
}
request_t *