queue2: only block serialized query when it's safe
authorWim Taymans <wim.taymans@collabora.co.uk>
Mon, 24 Jun 2013 21:25:51 +0000 (23:25 +0200)
committerWim Taymans <wim.taymans@collabora.co.uk>
Mon, 24 Jun 2013 21:29:16 +0000 (23:29 +0200)
commit2f78e962997725f734353ffe5c061f98b53903d8
tree95624644d83e6fb908844537aa1b40cba247de51
parent1815e6067a1077ddb92330b25f172da82f38a3e8
queue2: only block serialized query when it's safe

We must be certain that we don't cause a deadlock when blocking the serialized
queries. One such deadlock can happen when we are buffering and downstream is
blocked in preroll and a serialized query arrives. Downstream will not unblock
(and allow our query to execute) until we complete buffering and buffering will
not complete until we can answer the query..

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=702840
plugins/elements/gstqueue2.c