subtitleoverlay: fix state change stall on PAUSED->READY->PAUSED
authorAnssi Hannula <anssi.hannula@iki.fi>
Tue, 17 Jan 2012 14:05:41 +0000 (16:05 +0200)
committerVincent Penquerc'h <vincent.penquerch@collabora.co.uk>
Fri, 20 Jan 2012 17:29:06 +0000 (17:29 +0000)
commitdd8f9aca92df070157172bdeb97c93c33a3d5c22
tree1a42d79bac9d60a7479d9b942dbb8c8766e58964
parent71f70c98efe99aeea191f5c538bd269706928499
subtitleoverlay: fix state change stall on PAUSED->READY->PAUSED

After a PAUSED->READY change the sink pads are currently not set to
blocking state. When the element is set back to PAUSED, the change will
be done asynchronously, but as the _pad_blocked_cb() callback is now not
called, the state change never completes.

Fix that by setting the sink pads to blocking state on a PAUSED->READY
change, which ensures that the _pad_blocked_cb() is called when needed
on any future READY->PAUSED change. The sink pads are already put to
blocking state on NULL->READY change, so this behavior is consistent.

Fixes bug #668097.
gst/playback/gstsubtitleoverlay.c