提交 e66d2462 authored 作者: Travis Cross's avatar Travis Cross

Fix potential dereference of null pointer

The node could conceivably disappear before we grab the globals mutex
and we'd get back a null pointer.
上级 17137d08
......@@ -1791,7 +1791,7 @@ static void *SWITCH_THREAD_FUNC outbound_enterprise_thread_run(switch_thread_t *
switch_mutex_lock(globals.mutex);
node = switch_core_hash_find(globals.fifo_hash, h->node_name);
switch_thread_rwlock_rdlock(node->rwlock);
if (node) switch_thread_rwlock_rdlock(node->rwlock);
switch_mutex_unlock(globals.mutex);
if (node) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论