Use the new API to post flow ERROR messages on the bus

https://bugzilla.gnome.org/show_bug.cgi?id=770158
This commit is contained in:
Thibault Saunier 2016-08-19 11:09:27 -07:00 committed by Thibault Saunier
parent f70aa5b033
commit bc6aae6ca7
2 changed files with 3 additions and 7 deletions

View file

@ -4802,8 +4802,7 @@ seek_failed:
if (flushing) {
ret = GST_FLOW_FLUSHING;
} else {
GST_ELEMENT_ERROR (ogg, STREAM, DEMUX, (NULL),
("failed to start demuxing ogg"));
GST_ELEMENT_FLOW_ERROR (ogg, ret);
ret = GST_FLOW_ERROR;
}
goto pause;
@ -4845,9 +4844,7 @@ pause:
event = gst_event_new_eos ();
}
} else if (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_EOS) {
GST_ELEMENT_ERROR (ogg, STREAM, FAILED,
(_("Internal data stream error.")),
("stream stopped, reason %s", reason));
GST_ELEMENT_FLOW_ERROR (ogg, ret);
event = gst_event_new_eos ();
}

View file

@ -1520,8 +1520,7 @@ pause:
}
} else if (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_EOS) {
/* for fatal errors we post an error message */
GST_ELEMENT_ERROR (demux, STREAM, FAILED, (NULL),
("Stream stopped, reason %s", reason));
GST_ELEMENT_FLOW_ERROR (demux, ret);
push_eos = TRUE;
}
if (push_eos) {