gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_PLAYING);
/* and wait now */
g_cond_wait (block_data.cond, block_data.mutex);
- gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_NULL);
g_mutex_unlock (block_data.mutex);
+ gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_NULL);
g_mutex_free (block_data.mutex);
g_cond_free (block_data.cond);
gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_PLAYING);
/* and wait now */
g_cond_wait (block_data.cond, block_data.mutex);
- gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_NULL);
g_mutex_unlock (block_data.mutex);
+ gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_NULL);
g_mutex_free (block_data.mutex);
g_cond_free (block_data.cond);