[Freeswitch-trunk] [commit] r12721 - freeswitch/trunk/src/mod/applications/mod_lcr
FreeSWITCH SVN
rupa at freeswitch.org
Mon Mar 23 08:34:46 PDT 2009
Author: rupa
Date: Mon Mar 23 10:34:46 2009
New Revision: 12721
Log:
don't leak
Modified:
freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c
Modified: freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c (original)
+++ freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c Mon Mar 23 10:34:46 2009
@@ -563,6 +563,8 @@
/* format the custom_sql */
safe_sql = format_custom_sql(profile->custom_sql, cb_struct, digits_copy);
if (!safe_sql) {
+ switch_event_safe_destroy(&cb_struct->event);
+ switch_core_hash_destroy(&cb_struct->dedup_hash);
return SWITCH_STATUS_GENERR;
}
SWITCH_STANDARD_STREAM(sql_stream);
@@ -577,6 +579,7 @@
lookup_status = lcr_execute_sql_callback((char *)sql_stream.data, route_add_callback, cb_struct);
switch_safe_free(sql_stream.data);
+ switch_event_safe_destroy(&cb_struct->event);
switch_core_hash_destroy(&cb_struct->dedup_hash);
if (lookup_status) {
More information about the Freeswitch-trunk
mailing list