From c824fdd6cfbe1613f47b32e542d10f105f50ab4f Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Fri, 9 Jan 2015 02:32:57 -0800 Subject: [PATCH] cachemgr.cgi: memory leak in request parser Leaks a block of memory for each header parsed the size of the header. The CGI is rarely operating for long periods, it is run as-needed by servers so the memory leak does not accumulate long term. Detectd by Coverity Scan. Issue 1256164 --- tools/cachemgr.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/cachemgr.cc b/tools/cachemgr.cc index 63515a7f9a..d05dc63dce 100644 --- a/tools/cachemgr.cc +++ b/tools/cachemgr.cc @@ -1072,6 +1072,7 @@ read_request(void) req->workers = xstrdup(q); else if (0 == strcmp(t, "processes") && strlen(q)) req->processes = xstrdup(q); + safe_free(t); } if (req->server && !req->hostname) { -- 2.47.2