element: Don't hold state lock all the time while sending an event
authorSebastian Dröge <sebastian@centricular.com>
Thu, 10 Dec 2015 09:35:05 +0000 (11:35 +0200)
committerSebastian Dröge <sebastian@centricular.com>
Thu, 10 Dec 2015 09:35:05 +0000 (11:35 +0200)
commitb427997119a2b6aacbeb550f729936f8b963e24b
treec05de649354bc07e983eaee053c86fcab741a4ca
parenta7f8ad9c9a1a8842b55db4aec639a5f579cab345
element: Don't hold state lock all the time while sending an event

This lock seems to exist only to prevent elements from changing states while
events are being processed. However events are going to be processed
nonetheless in those elements if sent directly via pads, so protection must
already be implemented inside the elements for event handling if it is needed.

As such having the lock here is not very useful and is actually causing
various deadlocks in different situations as described in
https://bugzilla.gnome.org/show_bug.cgi?id=744040
gst/gstelement.c