From: Fabian Keil Date: Mon, 2 Mar 2020 11:36:40 +0000 (+0100) Subject: unload_configfile(): Use unload_forward_spec() instead of doing the work itself X-Git-Tag: v_3_0_29~449 X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=commitdiff_plain;h=04a8c84df57012d1b615db66862ef8cdb908d82a unload_configfile(): Use unload_forward_spec() instead of doing the work itself ... poorly. Previously the socks user name and password were leaked. Sponsored by: Robert Klemme --- diff --git a/loadcfg.c b/loadcfg.c index 0c8b8907..7d8c392c 100644 --- a/loadcfg.c +++ b/loadcfg.c @@ -239,11 +239,9 @@ static void unload_configfile (void * data) while (cur_fwd != NULL) { struct forward_spec * next_fwd = cur_fwd->next; - free_pattern_spec(cur_fwd->url); - freez(cur_fwd->gateway_host); - freez(cur_fwd->forward_host); - free(cur_fwd); + unload_forward_spec(cur_fwd); + cur_fwd = next_fwd; } config->forward = NULL;