]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
use mem.c for HttpStateData
authorwessels <>
Fri, 13 Mar 1998 12:40:46 +0000 (12:40 +0000)
committerwessels <>
Fri, 13 Mar 1998 12:40:46 +0000 (12:40 +0000)
src/enums.h
src/http.cc

index 16524fc7a217db95148f329d59891f20aaabc705..1a5867ec584ac8bf354184b426b1a08ae175fafe 100644 (file)
@@ -485,7 +485,7 @@ typedef enum {
     MEM_HTTP_HDR_RANGE_SPEC,
     MEM_HTTP_HDR_RANGE,
     MEM_HTTP_HDR_CONTENT_RANGE,
-    MEM_HTTPSTATEDATA,
+    MEM_HTTP_STATE_DATA,
     MEM_ICPUDPDATA,
     MEM_CLIENTHTTPREQUEST,
     MEM_CONNSTATEDATA,
index ad2543d64b9f6e310da07b5b18074e40942c179a..c188f61843dedc31d1ef09e68e3da3106c49d7f7 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: http.cc,v 1.250 1998/03/07 23:43:07 rousskov Exp $
+ * $Id: http.cc,v 1.251 1998/03/13 05:40:46 wessels Exp $
  *
  * DEBUG: section 11    Hypertext Transfer Protocol (HTTP)
  * AUTHOR: Harvest Derived
@@ -802,10 +802,10 @@ httpSocketOpen(StoreEntry * entry, request_t * request)
 static HttpStateData *
 httpBuildState(int fd, StoreEntry * entry, request_t * orig_request, peer * e)
 {
-    HttpStateData *httpState = xcalloc(1, sizeof(HttpStateData));
+    HttpStateData *httpState = memAllocate(MEM_HTTP_STATE_DATA);
     request_t *request;
     storeLockObject(entry);
-    cbdataAdd(httpState, MEM_NONE);
+    cbdataAdd(httpState, MEM_HTTP_STATE_DATA);
     httpState->entry = entry;
     httpState->fd = fd;
     if (e) {
@@ -813,11 +813,7 @@ httpBuildState(int fd, StoreEntry * entry, request_t * orig_request, peer * e)
        request->method = orig_request->method;
        xstrncpy(request->host, e->host, SQUIDHOSTNAMELEN);
        request->port = e->http_port;
-#if 0
-       xstrncpy(request->urlpath, storeUrl(entry), MAX_URL);
-#else
        stringReset(&request->urlpath, storeUrl(entry));
-#endif
        httpState->request = requestLink(request);
        httpState->peer = e;
        httpState->orig_request = requestLink(orig_request);