From: Michael Jerris Date: Fri, 16 May 2014 21:01:13 +0000 (+0000) Subject: CID:1087632 Resource leak X-Git-Tag: v1.4.4~31 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e1f8e199f06c802dda47ef760e119078015f4829;p=thirdparty%2Ffreeswitch.git CID:1087632 Resource leak --- diff --git a/src/switch_loadable_module.c b/src/switch_loadable_module.c index 0f4b0aa6e6..bd49e877a0 100644 --- a/src/switch_loadable_module.c +++ b/src/switch_loadable_module.c @@ -1364,9 +1364,10 @@ static switch_status_t switch_loadable_module_load_file(char *path, char *filena interface_struct_handle = switch_dso_data_sym(dso, struct_name, &derr); } - switch_safe_free(derr) + switch_safe_free(derr); - if (!interface_struct_handle) { + if (!interface_struct_handle) { + if (dso) switch_dso_destroy(&dso); dso = switch_dso_open(path, load_global, &derr); }