g_mutex_unlock hangs
Submitted by Rajesh
Link to original bug (#767480)
Description
we have a plugin which has a task waiting for signal for some activity. we are using gstreamer 1.5.2 for development and glib version is 2.34.1
src_pad_task () {
g_mutex_lock (mutex); if (var == TRUE) g_cond_wait (cond, mutex) g_mutex_unlock (mutex);
----- some buffer pushing code ----
return; }
we signal it from various places and also during state change from paused to ready as below.
case GST_STATE_CHANGE_PAUSED_TO_READY: -------- hw ioctls code ----------- g_mutex_lock (mutex); var = FALSE; g_cond_signal (cond); g_mutex_unlock (mutex); gst_pad_pause_task (srcpad);
in a very rare case (1 out of 50) chnage state gets struck in gst_pad_pause_task (srcpad) because g_mutex_unlock (mutex) is hang. this looks strange that g_mutex_unlock (mutex) is hang. what are the possible reasons of g_mutex_unlock (mutex) getting hang ?
BR/ Rajesh
Version: 2.34.x