From 3b292eaf91932295cb4556043361f34212266f0c Mon Sep 17 00:00:00 2001 From: Nathan Moinvaziri Date: Fri, 3 Feb 2023 12:32:36 -0800 Subject: [PATCH] Fixed memory leak in should_bypass_proxy during early exit. --- util.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util.c b/util.c index 450d384..9759811 100644 --- a/util.c +++ b/util.c @@ -447,8 +447,10 @@ bool should_bypass_proxy(const char *url, const char *bypass_list) { if (is_local) should_bypass = true; - if (!bypass_list) + if (!bypass_list) { + free(host); return should_bypass; + } // Check for simple hostnames if (strchr(host, '.') == NULL)