提交 457f7baa authored 作者: Andrey Volk's avatar Andrey Volk

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

上级 cdea1c13
...@@ -85,9 +85,8 @@ static void text_bridge_thread(switch_core_session_t *session, void *obj) ...@@ -85,9 +85,8 @@ static void text_bridge_thread(switch_core_session_t *session, void *obj)
if (inuse + 4 > text_framesize) { if (inuse + 4 > text_framesize) {
void *tmp = malloc(inuse + 1024); void *tmp = malloc(inuse + 1024);
memcpy(tmp, text_framedata, text_framesize);
switch_assert(tmp); switch_assert(tmp);
memcpy(tmp, text_framedata, text_framesize);
text_framesize = inuse + 1024; text_framesize = inuse + 1024;
...@@ -1914,7 +1913,7 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_multi_threaded_bridge(switch_core_ses ...@@ -1914,7 +1913,7 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_multi_threaded_bridge(switch_core_ses
explicit = !strcasecmp(hup, "explicit"); explicit = !strcasecmp(hup, "explicit");
} }
if (cause && !switch_channel_test_flag(peer_channel, CF_ANSWERED)) { if (!switch_channel_test_flag(peer_channel, CF_ANSWERED)) {
switch_channel_handle_cause(caller_channel, cause); switch_channel_handle_cause(caller_channel, cause);
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论