From: Anthony Minessale Date: Thu, 7 Dec 2006 18:16:29 +0000 (+0000) Subject: where did the read lock go in del_member X-Git-Tag: v1.0-beta1~1615 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=efd277768f60b8c4848b37df4bc408ab72d28f07;p=thirdparty%2Ffreeswitch.git where did the read lock go in del_member git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3567 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/mod/applications/mod_conference/mod_conference.c b/src/mod/applications/mod_conference/mod_conference.c index c6269959c9..36c5fd1485 100644 --- a/src/mod/applications/mod_conference/mod_conference.c +++ b/src/mod/applications/mod_conference/mod_conference.c @@ -473,6 +473,11 @@ static void conference_del_member(conference_obj_t *conference, conference_membe conference_member_t *imember, *last = NULL; switch_event_t *event; + if (switch_thread_rwlock_tryrdlock(conference->rwlock) != SWITCH_STATUS_SUCCESS) { + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Read Lock Fail\n"); + return; + } + switch_mutex_lock(conference->mutex); switch_mutex_lock(conference->member_mutex); switch_mutex_lock(member->audio_in_mutex);