]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
fix Proxy-connection: Keep-Alive check
authorwessels <>
Mon, 6 Apr 1998 02:32:44 +0000 (02:32 +0000)
committerwessels <>
Mon, 6 Apr 1998 02:32:44 +0000 (02:32 +0000)
rename pconn_keep_alive to proxy_keep_alive

src/HttpHeader.cc
src/HttpReply.cc
src/http.cc
src/structs.h

index 5295e856620c8dd4f186ea9e0111059a6df72c01..e1576878ea3bcce9e1fa489507b89d8080e6d056 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpHeader.cc,v 1.29 1998/04/03 22:26:32 rousskov Exp $
+ * $Id: HttpHeader.cc,v 1.30 1998/04/05 20:32:44 wessels Exp $
  *
  * DEBUG: section 55    HTTP Header
  * AUTHOR: Alex Rousskov
@@ -130,7 +130,7 @@ static http_hdr_type ListHeadersArr[] =
     HDR_ACCEPT_CHARSET, HDR_ACCEPT_ENCODING, HDR_ACCEPT_LANGUAGE,
     HDR_ACCEPT_RANGES,
     /* HDR_ALLOW, */
-    HDR_CACHE_CONTROL, HDR_CONNECTION,
+    HDR_CACHE_CONTROL,
     HDR_CONTENT_ENCODING,
     /* HDR_CONTENT_LANGUAGE, */
     /*  HDR_IF_MATCH, HDR_IF_NONE_MATCH, HDR_PRAGMA, */
index a10bd7ee05202626cf6e9a6e52a56fdbb8c2feab..b6bc07b6baa64b9fd1d67a50806b20f4a282393e 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: HttpReply.cc,v 1.13 1998/03/20 18:06:39 rousskov Exp $
+ * $Id: HttpReply.cc,v 1.14 1998/04/05 20:32:44 wessels Exp $
  *
  * DEBUG: section 58    HTTP Reply (Response)
  * AUTHOR: Alex Rousskov
@@ -270,7 +270,9 @@ httpReplyHdrCacheInit(HttpReply * rep)
     rep->cache_control = httpHeaderGetCc(hdr);
     rep->content_range = httpHeaderGetContRange(hdr);
     str = httpHeaderGetStr(hdr, HDR_PROXY_CONNECTION);
-    rep->pconn_keep_alive = str && strcasecmp(str, "Keep-Alive");
+    if (NULL == str)
+        str = httpHeaderGetStr(hdr, HDR_CONNECTION);   /* @?@ FIX ME */
+    rep->proxy_keep_alive = str && 0 == strcasecmp(str, "Keep-Alive");
     /* final adjustments */
     /* The max-age directive takes priority over Expires, check it first */
     if (rep->cache_control && rep->cache_control->max_age >= 0)
index 51a11b774cd0f4ac2227306259461910c02ea14d..d0460a91b19d85d0ab3fbcac41a660496e27dc69 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: http.cc,v 1.262 1998/04/01 21:23:01 wessels Exp $
+ * $Id: http.cc,v 1.263 1998/04/05 20:32:45 wessels Exp $
  *
  * DEBUG: section 11    Hypertext Transfer Protocol (HTTP)
  * AUTHOR: Harvest Derived
@@ -366,7 +366,7 @@ httpProcessReplyHeader(HttpStateData * httpState, const char *buf, int size)
        if (EBIT_TEST(httpState->flags, HTTP_KEEPALIVE))
            if (httpState->peer)
                httpState->peer->stats.n_keepalives_sent++;
-       if (reply->pconn_keep_alive)
+       if (reply->proxy_keep_alive)
            if (httpState->peer)
                httpState->peer->stats.n_keepalives_recv++;
        ctx_exit(ctx);
index 74b1669d088f72a17a79f336daf986f026dfb38e..28e0eb43f32423246c3400e4f0ecc8ab73bbd806 100644 (file)
@@ -567,7 +567,7 @@ struct _HttpReply {
     String content_type;
     HttpHdrCc *cache_control;
     HttpHdrContRange *content_range;
-    short int pconn_keep_alive;
+    short int proxy_keep_alive;
 
     /* public, readable */
     HttpMsgParseState pstate;  /* the current parsing state */