summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/gme/gstgme.c4
-rw-r--r--ext/sndfile/gstsfsink.c4
-rw-r--r--ext/teletextdec/gstteletextdec.c4
-rw-r--r--ext/timidity/gsttimidity.c4
-rw-r--r--ext/timidity/gstwildmidi.c4
-rw-r--r--gst-libs/gst/adaptivedemux/gstadaptivedemux.c15
-rw-r--r--gst/aiff/aiffparse.c4
-rw-r--r--gst/midi/midiparse.c4
-rw-r--r--gst/mpegdemux/gstmpegdemux.c4
-rw-r--r--gst/mpegtsdemux/mpegtsbase.c4
-rw-r--r--gst/mxf/mxfdemux.c4
-rw-r--r--gst/nuvdemux/gstnuvdemux.c4
-rw-r--r--gst/tta/gstttaparse.c4
-rw-r--r--sys/androidmedia/gstamcaudiodec.c4
-rw-r--r--sys/androidmedia/gstamcvideodec.c4
-rw-r--r--sys/androidmedia/gstamcvideoenc.c4
-rw-r--r--sys/applemedia/avfassetsrc.m3
17 files changed, 24 insertions, 54 deletions
diff --git a/ext/gme/gstgme.c b/ext/gme/gstgme.c
index 1c5c83c41..4fb44295f 100644
--- a/ext/gme/gstgme.c
+++ b/ext/gme/gstgme.c
@@ -353,9 +353,7 @@ gst_gme_play (GstPad * pad)
if (flow_return == GST_FLOW_EOS) {
gst_pad_push_event (pad, gst_event_new_eos ());
} else if (flow_return < GST_FLOW_EOS || flow_return == GST_FLOW_NOT_LINKED) {
- GST_ELEMENT_ERROR (gme, STREAM, FAILED, ("Internal data stream error."),
- ("stream stopped, reason %s", gst_flow_get_name (flow_return)));
-
+ GST_ELEMENT_FLOW_ERROR (gme, flow_return);
gst_pad_push_event (pad, gst_event_new_eos ());
}
}
diff --git a/ext/sndfile/gstsfsink.c b/ext/sndfile/gstsfsink.c
index 78f709838..219f1a9aa 100644
--- a/ext/sndfile/gstsfsink.c
+++ b/ext/sndfile/gstsfsink.c
@@ -433,9 +433,7 @@ paused:
if (result == GST_FLOW_UNEXPECTED) {
gst_pad_send_event (pad, gst_event_new_eos ());
} else if (result < GST_FLOW_UNEXPECTED || result == GST_FLOW_NOT_LINKED) {
- GST_ELEMENT_ERROR (basesink, STREAM, FAILED,
- (_("Internal data stream error.")),
- ("stream stopped, reason %s", gst_flow_get_name (result)));
+ GST_ELEMENT_FLOW_ERROR (basesink, result);
gst_pad_send_event (pad, gst_event_new_eos ());
}
gst_object_unref (this);
diff --git a/ext/teletextdec/gstteletextdec.c b/ext/teletextdec/gstteletextdec.c
index 5909a76ee..7f8a8a690 100644
--- a/ext/teletextdec/gstteletextdec.c
+++ b/ext/teletextdec/gstteletextdec.c
@@ -743,9 +743,7 @@ error:
{
if (ret != GST_FLOW_OK && ret != GST_FLOW_NOT_LINKED
&& ret != GST_FLOW_FLUSHING) {
- GST_ELEMENT_ERROR (teletext, STREAM, FAILED,
- ("Internal data stream error."), ("stream stopped, reason %s",
- gst_flow_get_name (ret)));
+ GST_ELEMENT_FLOW_ERROR (teletext, ret);
return GST_FLOW_ERROR;
}
return ret;
diff --git a/ext/timidity/gsttimidity.c b/ext/timidity/gsttimidity.c
index f7af843f3..207869400 100644
--- a/ext/timidity/gsttimidity.c
+++ b/ext/timidity/gsttimidity.c
@@ -743,9 +743,7 @@ eos:
}
error:
{
- GST_ELEMENT_ERROR (timidity, STREAM, FAILED,
- ("Internal data stream error"),
- ("Streaming stopped, reason %s", gst_flow_get_name (ret)));
+ GST_ELEMENT_FLOW_ERROR (timidity, ret);
gst_pad_push_event (timidity->srcpad, gst_event_new_eos ());
goto paused;
}
diff --git a/ext/timidity/gstwildmidi.c b/ext/timidity/gstwildmidi.c
index f52ea9d98..7f380d6da 100644
--- a/ext/timidity/gstwildmidi.c
+++ b/ext/timidity/gstwildmidi.c
@@ -898,9 +898,7 @@ pause:
event = gst_event_new_eos ();
/* for fatal errors we post an error message, post the error
* first so the app knows about the error first. */
- GST_ELEMENT_ERROR (wildmidi, STREAM, FAILED,
- ("Internal data flow error."),
- ("streaming task paused, reason %s (%d)", reason, ret));
+ GST_ELEMENT_FLOW_ERROR (wildmidi, ret);
gst_pad_push_event (wildmidi->srcpad, event);
}
}
diff --git a/gst-libs/gst/adaptivedemux/gstadaptivedemux.c b/gst-libs/gst/adaptivedemux/gstadaptivedemux.c
index e51f6ddde..c465226ee 100644
--- a/gst-libs/gst/adaptivedemux/gstadaptivedemux.c
+++ b/gst-libs/gst/adaptivedemux/gstadaptivedemux.c
@@ -2230,8 +2230,7 @@ _src_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
gboolean finished = FALSE;
if (ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (demux, STREAM, FAILED, (NULL),
- ("stream stopped, reason %s", gst_flow_get_name (ret)));
+ GST_ELEMENT_FLOW_ERROR (demux, ret);
/* TODO push this on all pads */
gst_pad_push_event (stream->pad, gst_event_new_eos ());
@@ -3285,13 +3284,15 @@ gst_adaptive_demux_stream_download_loop (GstAdaptiveDemuxStream * stream)
break;
case GST_FLOW_NOT_LINKED:
+ {
+ GstFlowReturn ret;
gst_task_stop (stream->download_task);
- if (gst_adaptive_demux_combine_flows (demux)
- == GST_FLOW_NOT_LINKED) {
- GST_ELEMENT_ERROR (demux, STREAM, FAILED,
- (_("Internal data stream error.")), ("stream stopped, reason %s",
- gst_flow_get_name (GST_FLOW_NOT_LINKED)));
+
+ ret = gst_adaptive_demux_combine_flows (demux);
+ if (ret == GST_FLOW_NOT_LINKED) {
+ GST_ELEMENT_FLOW_ERROR (demux, ret);
}
+ }
break;
case GST_FLOW_FLUSHING:{
diff --git a/gst/aiff/aiffparse.c b/gst/aiff/aiffparse.c
index 194857be3..faa264770 100644
--- a/gst/aiff/aiffparse.c
+++ b/gst/aiff/aiffparse.c
@@ -1527,9 +1527,7 @@ pause:
} else if (ret < GST_FLOW_EOS || ret == GST_FLOW_NOT_LINKED) {
/* for fatal errors we post an error message, post the error
* first so the app knows about the error first. */
- GST_ELEMENT_ERROR (aiff, STREAM, FAILED,
- (_("Internal data flow error.")),
- ("streaming task paused, reason %s (%d)", reason, ret));
+ GST_ELEMENT_FLOW_ERROR (aiff, ret);
gst_pad_push_event (aiff->srcpad, gst_event_new_eos ());
}
return;
diff --git a/gst/midi/midiparse.c b/gst/midi/midiparse.c
index d52539b3c..d58ea3f49 100644
--- a/gst/midi/midiparse.c
+++ b/gst/midi/midiparse.c
@@ -1282,9 +1282,7 @@ pause:
event = gst_event_new_eos ();
/* for fatal errors we post an error message, post the error
* first so the app knows about the error first. */
- GST_ELEMENT_ERROR (midiparse, STREAM, FAILED,
- ("Internal data flow error."),
- ("streaming task paused, reason %s (%d)", reason, ret));
+ GST_ELEMENT_FLOW_ERROR (midiparse, ret);
gst_pad_push_event (midiparse->srcpad, event);
}
}
diff --git a/gst/mpegdemux/gstmpegdemux.c b/gst/mpegdemux/gstmpegdemux.c
index 68985b2ab..b608db867 100644
--- a/gst/mpegdemux/gstmpegdemux.c
+++ b/gst/mpegdemux/gstmpegdemux.c
@@ -3005,9 +3005,7 @@ pause:
}
}
} else if (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (demux, STREAM, FAILED,
- ("Internal data stream error."),
- ("stream stopped, reason %s", reason));
+ GST_ELEMENT_FLOW_ERROR (demux, ret);
gst_ps_demux_send_event (demux, gst_event_new_eos ());
}
diff --git a/gst/mpegtsdemux/mpegtsbase.c b/gst/mpegtsdemux/mpegtsbase.c
index cf69a18d0..e736f9bf4 100644
--- a/gst/mpegtsdemux/mpegtsbase.c
+++ b/gst/mpegtsdemux/mpegtsbase.c
@@ -1382,9 +1382,7 @@ error:
(_("Internal data stream error.")),
("No program activated before EOS"));
} else if (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (base, STREAM, FAILED,
- (_("Internal data stream error.")),
- ("stream stopped, reason %s", reason));
+ GST_ELEMENT_FLOW_ERROR (base, ret);
GST_MPEGTS_BASE_GET_CLASS (base)->push_event (base, gst_event_new_eos ());
}
gst_pad_pause_task (base->sinkpad);
diff --git a/gst/mxf/mxfdemux.c b/gst/mxf/mxfdemux.c
index ca09cc7ac..823b1b6ff 100644
--- a/gst/mxf/mxfdemux.c
+++ b/gst/mxf/mxfdemux.c
@@ -3098,9 +3098,7 @@ pause:
} else if (flow == GST_FLOW_NOT_LINKED || flow < GST_FLOW_EOS) {
GstEvent *e;
- GST_ELEMENT_ERROR (demux, STREAM, FAILED,
- ("Internal data stream error."),
- ("stream stopped, reason %s", reason));
+ GST_ELEMENT_FLOW_ERROR (demux, flow);
e = gst_event_new_eos ();
gst_event_set_seqnum (e, demux->seqnum);
gst_mxf_demux_push_src_event (demux, e);
diff --git a/gst/nuvdemux/gstnuvdemux.c b/gst/nuvdemux/gstnuvdemux.c
index b98d35df4..88968f0a1 100644
--- a/gst/nuvdemux/gstnuvdemux.c
+++ b/gst/nuvdemux/gstnuvdemux.c
@@ -729,9 +729,7 @@ pause:
if (res == GST_FLOW_UNEXPECTED) {
gst_nuv_demux_send_eos (nuv);
} else if (res == GST_FLOW_NOT_LINKED || res < GST_FLOW_UNEXPECTED) {
- GST_ELEMENT_ERROR (nuv, STREAM, FAILED,
- (_("Internal data stream error.")),
- ("streaming stopped, reason %s", gst_flow_get_name (res)));
+ GST_ELEMENT_FLOW_ERROR (nuv, res);
gst_nuv_demux_send_eos (nuv);
}
diff --git a/gst/tta/gstttaparse.c b/gst/tta/gstttaparse.c
index 5479350cd..485a19746 100644
--- a/gst/tta/gstttaparse.c
+++ b/gst/tta/gstttaparse.c
@@ -468,9 +468,7 @@ pause:
if (ret == GST_FLOW_UNEXPECTED) {
gst_pad_push_event (ttaparse->srcpad, gst_event_new_eos ());
} else if (ret < GST_FLOW_UNEXPECTED || ret == GST_FLOW_NOT_LINKED) {
- GST_ELEMENT_ERROR (ttaparse, STREAM, FAILED,
- ("Internal data stream error."),
- ("streaming stopped, reason %s", gst_flow_get_name (ret)));
+ GST_ELEMENT_FLOW_ERROR (ttaparse, ret);
gst_pad_push_event (ttaparse->srcpad, gst_event_new_eos ());
}
}
diff --git a/sys/androidmedia/gstamcaudiodec.c b/sys/androidmedia/gstamcaudiodec.c
index 9a34c375c..49c8c602c 100644
--- a/sys/androidmedia/gstamcaudiodec.c
+++ b/sys/androidmedia/gstamcaudiodec.c
@@ -670,9 +670,7 @@ flow_error:
gst_event_new_eos ());
gst_pad_pause_task (GST_AUDIO_DECODER_SRC_PAD (self));
} else if (flow_ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (self, STREAM, FAILED,
- ("Internal data stream error."), ("stream stopped, reason %s",
- gst_flow_get_name (flow_ret)));
+ GST_ELEMENT_FLOW_ERROR (self, flow_ret);
gst_pad_push_event (GST_AUDIO_DECODER_SRC_PAD (self),
gst_event_new_eos ());
gst_pad_pause_task (GST_AUDIO_DECODER_SRC_PAD (self));
diff --git a/sys/androidmedia/gstamcvideodec.c b/sys/androidmedia/gstamcvideodec.c
index 397b5857b..bd772b739 100644
--- a/sys/androidmedia/gstamcvideodec.c
+++ b/sys/androidmedia/gstamcvideodec.c
@@ -1590,9 +1590,7 @@ flow_error:
gst_event_new_eos ());
gst_pad_pause_task (GST_VIDEO_DECODER_SRC_PAD (self));
} else if (flow_ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (self, STREAM, FAILED,
- ("Internal data stream error."), ("stream stopped, reason %s",
- gst_flow_get_name (flow_ret)));
+ GST_ELEMENT_FLOW_ERROR (self, flow_ret);
gst_pad_push_event (GST_VIDEO_DECODER_SRC_PAD (self),
gst_event_new_eos ());
gst_pad_pause_task (GST_VIDEO_DECODER_SRC_PAD (self));
diff --git a/sys/androidmedia/gstamcvideoenc.c b/sys/androidmedia/gstamcvideoenc.c
index 136df4197..1742d444a 100644
--- a/sys/androidmedia/gstamcvideoenc.c
+++ b/sys/androidmedia/gstamcvideoenc.c
@@ -1129,9 +1129,7 @@ flow_error:
gst_event_new_eos ());
gst_pad_pause_task (GST_VIDEO_ENCODER_SRC_PAD (self));
} else if (flow_ret == GST_FLOW_NOT_LINKED || flow_ret < GST_FLOW_EOS) {
- GST_ELEMENT_ERROR (self, STREAM, FAILED,
- ("Internal data stream error."), ("stream stopped, reason %s",
- gst_flow_get_name (flow_ret)));
+ GST_ELEMENT_FLOW_ERROR (self, flow_ret);
gst_pad_push_event (GST_VIDEO_ENCODER_SRC_PAD (self),
gst_event_new_eos ());
gst_pad_pause_task (GST_VIDEO_ENCODER_SRC_PAD (self));
diff --git a/sys/applemedia/avfassetsrc.m b/sys/applemedia/avfassetsrc.m
index 388d7e13e..856828160 100644
--- a/sys/applemedia/avfassetsrc.m
+++ b/sys/applemedia/avfassetsrc.m
@@ -535,8 +535,7 @@ gst_avf_asset_src_read_data (GstAVFAssetSrc *self, GstPad *pad,
}
if (combined_ret != GST_FLOW_OK) {
- GST_ELEMENT_ERROR (self, STREAM, FAILED, ("Internal data stream error."),
- ("stream stopped reason %s", gst_flow_get_name (ret)));
+ GST_ELEMENT_FLOW_ERROR (self, ret);
}
gst_pad_pause_task (pad);