FS-4867: --resolve Prevent possible deadlock due to mutexes locked in opposite order between switch_ivr_dmachine_ping and switch_channel_queue_dtmf

This commit is contained in:
William King 2013-01-15 13:06:44 -08:00
parent c8c0984136
commit 9b33675545
1 changed files with 2 additions and 0 deletions

View File

@ -151,7 +151,9 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_read_frame(switch_core_sessi
for(i = 0; i < 2; i++) {
if (session->dmachine[i] && !switch_channel_test_flag(session->channel, CF_BROADCAST)) {
switch_mutex_lock(session->channel->dtmf_mutex);
switch_ivr_dmachine_ping(session->dmachine[i], NULL);
switch_mutex_unlock(session->channel->dtmf_mutex);
}
}