mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-11-13 04:57:05 +00:00
[core, mod_cidlookup] Free memory allocated via strdup
In mod_cidlookup and several other modules, config parameters are read from external XML files using the SWITCH_CONFIG_ITEM_STRING_STRDUP method. These items do not have string_options, and are not freed with switch_xml_config_cleanup. We therefore need to call switch_safe_free for config without string_options. We also add switch_xml_config_cleanup to mod_cidlookup. There are other modules that may be affected but this commit makes no attempt at fixing those. Fixes #1752
This commit is contained in:
1 parent
f680a29405
commit
965e88a6b0
2 files changed
+2
-1
No files matched your search
@@ -845,6 +845,7 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_cidlookup_load)
|
||||
Macro expands to: switch_status_t mod_cidlookup_shutdown() */
|
||||
SWITCH_MODULE_SHUTDOWN_FUNCTION(mod_cidlookup_shutdown)
|
||||
{
|
||||
switch_xml_config_cleanup(instructions);
|
||||
switch_event_unbind(&reload_xml_event);
|
||||
return SWITCH_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user