]> granicus.if.org Git - apache/commitdiff
fix memory leak. Reported by <christophe.jaillet@wanadoo.fr>
authorBill Stoddard <stoddard@apache.org>
Wed, 2 Nov 2005 22:42:45 +0000 (22:42 +0000)
committerBill Stoddard <stoddard@apache.org>
Wed, 2 Nov 2005 22:42:45 +0000 (22:42 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@330380 13f79535-47bb-0310-9956-ffa450edef68

modules/cache/mod_mem_cache.c

index efe0a18d734be537eff3c7387c2a429341806cb2..2d45c2cd8e507655b1413d34fab28f9ba3f7de30 100644 (file)
@@ -568,6 +568,7 @@ static apr_status_t serialize_table(cache_header_tbl_t **obj,
     /* Transfer the headers into a contiguous memory block */
     buf = malloc(len);
     if (!buf) {
+        free(*obj);
         *obj = NULL;
         return APR_ENOMEM;
     }