summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorTilghman Lesher <tilghman@meg.abyt.es>2008-10-14 22:38:06 +0000
committerTilghman Lesher <tilghman@meg.abyt.es>2008-10-14 22:38:06 +0000
commitd5837ba8c275b75388815a3263dae97cf306161b (patch)
tree96325674713833036b2bd7758905df5ccb47ca65 /channels
parentc6caf2a06fb2e316ac8b23561955ea95f7bc7598 (diff)
Add additional memory debugging to several core APIs, and fix several memory
leaks found with these changes. (Closes issue #13505, closes issue #13543) Reported by: mav3rick, triccyx Patches: 20081001__bug13505.diff.txt uploaded by Corydon76 (license 14) Tested by: mav3rick, triccyx git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@149199 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index f535e3ed8..8573e6316 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -21820,6 +21820,12 @@ static int reload_config(enum channelreloadreason reason)
}
/* Reset certificate handling for TLS sessions */
+ if (reason != CHANNEL_MODULE_LOAD) {
+ ast_free(default_tls_cfg.certfile);
+ ast_free(default_tls_cfg.cipher);
+ ast_free(default_tls_cfg.cafile);
+ ast_free(default_tls_cfg.capath);
+ }
default_tls_cfg.certfile = ast_strdup(AST_CERTFILE); /*XXX Not sure if this is useful */
default_tls_cfg.cipher = ast_strdup("");
default_tls_cfg.cafile = ast_strdup("");