提交 862e675f authored 作者: Andrey Volk's avatar Andrey Volk

FS-11903: Fix errors reported by PVS-Studio Static Code Analyzer for switch_loadable_module.c

上级 0893418d
...@@ -2525,9 +2525,7 @@ SWITCH_DECLARE(switch_endpoint_interface_t *) switch_loadable_module_get_endpoin ...@@ -2525,9 +2525,7 @@ SWITCH_DECLARE(switch_endpoint_interface_t *) switch_loadable_module_get_endpoin
switch_mutex_lock(loadable_modules.mutex); switch_mutex_lock(loadable_modules.mutex);
ptr = switch_core_hash_find(loadable_modules.endpoint_hash, name); ptr = switch_core_hash_find(loadable_modules.endpoint_hash, name);
if (ptr) { PROTECT_INTERFACE(ptr);
PROTECT_INTERFACE(ptr);
}
switch_mutex_unlock(loadable_modules.mutex); switch_mutex_unlock(loadable_modules.mutex);
...@@ -2611,9 +2609,7 @@ SWITCH_DECLARE(switch_codec_interface_t *) switch_loadable_module_get_codec_inte ...@@ -2611,9 +2609,7 @@ SWITCH_DECLARE(switch_codec_interface_t *) switch_loadable_module_get_codec_inte
switch_mutex_unlock(loadable_modules.mutex); switch_mutex_unlock(loadable_modules.mutex);
if (codec) { PROTECT_INTERFACE(codec);
PROTECT_INTERFACE(codec);
}
return codec; return codec;
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论