]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
cleanup after yourself
authorAnthony Minessale <anthm@freeswitch.org>
Mon, 2 Apr 2012 21:20:35 +0000 (16:20 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Mon, 2 Apr 2012 21:20:40 +0000 (16:20 -0500)
libs/freetdm/mod_freetdm/mod_freetdm.c

index 1c41ed3b742cf689a2ec8b4813b5c6378cb274cf..9b6641d7b0cc8e281cf1cf4e5a8212e3648b2546 100755 (executable)
@@ -4834,11 +4834,13 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_freetdm_load)
        ftdm_global_set_config_directory(SWITCH_GLOBAL_dirs.conf_dir);
 
        if (ftdm_global_init() != FTDM_SUCCESS) {
+               ftdm_global_destroy();
                ftdm_log(FTDM_LOG_ERROR, "Error loading FreeTDM\n");
                return SWITCH_STATUS_TERM;
        }
 
        if (ftdm_global_configuration() != FTDM_SUCCESS) {
+               ftdm_global_destroy();
                ftdm_log(FTDM_LOG_ERROR, "Error configuring FreeTDM\n");
                return SWITCH_STATUS_TERM;
        }