From: Anthony Minessale Date: Tue, 3 Mar 2015 23:45:32 +0000 (-0600) Subject: FS-7500: try not do X-Git-Tag: v1.6.2~614^2~312 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee095754663749f0cbfc3e83c2f4068a74604f5e;p=thirdparty%2Ffreeswitch.git FS-7500: try not do --- diff --git a/src/switch_core_media.c b/src/switch_core_media.c index 32f40ff384..25d3077be6 100644 --- a/src/switch_core_media.c +++ b/src/switch_core_media.c @@ -10046,7 +10046,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_write_video_frame(switch_cor } //v_engine = &smh->engines[SWITCH_MEDIA_TYPE_VIDEO]; - if (smh->write_mutex[SWITCH_MEDIA_TYPE_VIDEO] && switch_mutex_lock(smh->write_mutex[SWITCH_MEDIA_TYPE_VIDEO]) != SWITCH_STATUS_SUCCESS) { + if (smh->write_mutex[SWITCH_MEDIA_TYPE_VIDEO] && switch_mutex_trylock(smh->write_mutex[SWITCH_MEDIA_TYPE_VIDEO]) != SWITCH_STATUS_SUCCESS) { /* return CNG, another thread is already writing */ switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG1, "%s is already being written to for %s\n", switch_channel_get_name(session->channel), type2str(SWITCH_MEDIA_TYPE_VIDEO));