]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
- Bug fix: we did not set body.buf if freefunc != NULL in httpBodySet
authorrousskov <>
Fri, 10 Apr 1998 05:40:39 +0000 (05:40 +0000)
committerrousskov <>
Fri, 10 Apr 1998 05:40:39 +0000 (05:40 +0000)
src/HttpBody.cc

index fddc77f04577377e2b7db1f28a3d362fedf17898..099cf5b2d0b9f7aa61b7ae280a79dbfee5f959f7 100644 (file)
@@ -1,7 +1,7 @@
 
 
 /*
- * $Id: HttpBody.cc,v 1.6 1998/03/31 05:35:36 wessels Exp $
+ * $Id: HttpBody.cc,v 1.7 1998/04/09 23:40:39 rousskov Exp $
  *
  * DEBUG: section 56    HTTP Message Body
  * AUTHOR: Alex Rousskov
@@ -71,6 +71,8 @@ httpBodySet(HttpBody * body, const char *buf, int size, FREE * freefunc)
        body->buf = xmalloc(size);
        xmemcpy(body->buf, buf, size);
        freefunc = &xfree;
+    } else {
+       body->buf = buf;
     }
     body->freefunc = freefunc;
     body->size = size;