playsink: Immediately error out if state change fails

Otherwise we chain up to the parent class' change_state function and might
override the failure with SUCCESS.

https://bugzilla.gnome.org/show_bug.cgi?id=756611
This commit is contained in:
Sebastian Dröge 2015-10-17 22:20:31 +03:00
parent 92061cb19e
commit 87dbe54797

View file

@ -4769,8 +4769,10 @@ gst_play_sink_change_state (GstElement * element, GstStateChange transition)
ret = GST_STATE_CHANGE_ASYNC;
/* block all pads here */
if (!gst_play_sink_reconfigure (playsink))
if (!gst_play_sink_reconfigure (playsink)) {
ret = GST_STATE_CHANGE_FAILURE;
goto activate_failed;
}
break;
case GST_STATE_CHANGE_PAUSED_TO_READY:
/* unblock all pads here */