summaryrefslogtreecommitdiff
authorCarl-Anton Ingmarsson <ca.ingmarsson@gmail.com>2010-07-27 21:17:09 (GMT)
committer Carl-Anton Ingmarsson <ca.ingmarsson@gmail.com>2010-07-30 09:31:59 (GMT)
commitd564e1bf19cbeb4bd5aae9cbf92b79445fde96c8 (patch) (side-by-side diff)
tree4a4033e3ec7f837b59620a34a33750fcc4f566f0
parent86860beeaecb747b98014ac5eb6d89c64ac85f60 (diff)
downloadgst-plugins-bad-d564e1bf19cbeb4bd5aae9cbf92b79445fde96c8.zip
gst-plugins-bad-d564e1bf19cbeb4bd5aae9cbf92b79445fde96c8.tar.gz
vdpau: fix GstBaseVideoDecoder returning wrong GstStateChangeReturn
when gst_base_video_decoder_[start|stop] fails we now return GST_STATE_CHANGE_FAILURE instead of returning what the parent class returns
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--sys/vdpau/basevideodecoder/gstbasevideodecoder.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/vdpau/basevideodecoder/gstbasevideodecoder.c b/sys/vdpau/basevideodecoder/gstbasevideodecoder.c
index 353badf..1e9cf14 100644
--- a/sys/vdpau/basevideodecoder/gstbasevideodecoder.c
+++ b/sys/vdpau/basevideodecoder/gstbasevideodecoder.c
@@ -917,7 +917,8 @@ gst_base_video_decoder_change_state (GstElement * element,
switch (transition) {
case GST_STATE_CHANGE_READY_TO_PAUSED:
- gst_base_video_decoder_start (base_video_decoder);
+ if (!gst_base_video_decoder_start (base_video_decoder))
+ return GST_STATE_CHANGE_FAILURE;
break;
default:
@@ -928,7 +929,8 @@ gst_base_video_decoder_change_state (GstElement * element,
switch (transition) {
case GST_STATE_CHANGE_PAUSED_TO_READY:
- gst_base_video_decoder_stop (base_video_decoder);
+ if (!gst_base_video_decoder_stop (base_video_decoder))
+ ret = GST_STATE_CHANGE_FAILURE;
break;
default: