Fix various memory leaks

main/config.c - cleanup cache fie includes
res/res_security_log.c - unregister logger level
channesl/chan_sip.c - cleanup io context and notify_types
main/translator.c - cleanup at shutdown
main/named_acl.c - cleanup cli commands
main/indications.c - ast_get_indication_tone() unref default_tone_zone if used

(closes issues ASTERISK-22378)
Reported by: Corey Farrell
Patches:
     config_shutdown.patch uploaded by coreyfarrell (license 5909)
     res_security_log.patch uploaded by coreyfarrell (license 5909)
     chan_sip-11.patch uploaded by coreyfarrell (license 5909)
     indications_refleak.patch uploaded by coreyfarrell (license 5909)
     named_acl-cli_unreg-trunk.patch uploaded by coreyfarrell (license 5909)
     translate_shutdown.patch uploaded by coreyfarrell (license 5909)

........

Merged revisions 398102 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 398103 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/12@398116 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin Harwell
2013-08-30 19:20:47 +00:00
parent 5c78e0c3f0
commit 35e44ccf9c
6 changed files with 37 additions and 0 deletions

View File

@@ -34662,7 +34662,12 @@ static int unload_module(void)
clear_sip_domains();
sip_cfg.contact_acl = ast_free_acl_list(sip_cfg.contact_acl);
if (sipsock_read_id) {
ast_io_remove(io, sipsock_read_id);
sipsock_read_id = NULL;
}
close(sipsock);
io_context_destroy(io);
ast_sched_context_destroy(sched);
con = ast_context_find(used_context);
if (con) {
@@ -34676,6 +34681,11 @@ static int unload_module(void)
sip_reqresp_parser_exit();
sip_unregister_tests();
if (notify_types) {
ast_config_destroy(notify_types);
notify_types = NULL;
}
ast_format_cap_destroy(sip_tech.capabilities);
sip_cfg.caps = ast_format_cap_destroy(sip_cfg.caps);