mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-24 16:18:16 +00:00
remove prematurely added error category and clean up the instances
Original commit message from CVS: remove prematurely added error category and clean up the instances
This commit is contained in:
parent
62cfdde715
commit
013e3acc3d
10 changed files with 43 additions and 29 deletions
10
ChangeLog
10
ChangeLog
|
@ -1,3 +1,13 @@
|
||||||
|
2005-10-23 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||||
|
|
||||||
|
* gst/base/gstbasesink.c: (gst_base_sink_handle_object):
|
||||||
|
* gst/base/gstbasesrc.c: (gst_base_src_loop):
|
||||||
|
* gst/gsterror.c: (_gst_stream_errors_init):
|
||||||
|
* gst/gsterror.h:
|
||||||
|
* gst/gstqueue.c: (gst_queue_loop):
|
||||||
|
* po/POTFILES.in:
|
||||||
|
remove prematurely added error category and clean up the instances
|
||||||
|
|
||||||
2005-10-21 Wim Taymans <wim@fluendo.com>
|
2005-10-21 Wim Taymans <wim@fluendo.com>
|
||||||
|
|
||||||
* gst/base/gstbasesink.c: (gst_base_sink_commit_state),
|
* gst/base/gstbasesink.c: (gst_base_sink_commit_state),
|
||||||
|
|
|
@ -42,6 +42,7 @@
|
||||||
|
|
||||||
#include "gstbasesink.h"
|
#include "gstbasesink.h"
|
||||||
#include <gst/gstmarshal.h>
|
#include <gst/gstmarshal.h>
|
||||||
|
#include <gst/gst-i18n-lib.h>
|
||||||
|
|
||||||
GST_DEBUG_CATEGORY_STATIC (gst_base_sink_debug);
|
GST_DEBUG_CATEGORY_STATIC (gst_base_sink_debug);
|
||||||
#define GST_CAT_DEFAULT gst_base_sink_debug
|
#define GST_CAT_DEFAULT gst_base_sink_debug
|
||||||
|
@ -622,8 +623,8 @@ gst_base_sink_handle_object (GstBaseSink * basesink, GstPad * pad,
|
||||||
GstBuffer *buf = GST_BUFFER (obj);
|
GstBuffer *buf = GST_BUFFER (obj);
|
||||||
|
|
||||||
if (!basesink->have_newsegment) {
|
if (!basesink->have_newsegment) {
|
||||||
GST_ELEMENT_WARNING (basesink, STREAM, STOPPED,
|
GST_ELEMENT_WARNING (basesink, STREAM, FAILED,
|
||||||
("Received buffer without a new-segment. Cannot sync to clock."),
|
(_("Internal data flow problem.")),
|
||||||
("Received buffer without a new-segment. Cannot sync to clock."));
|
("Received buffer without a new-segment. Cannot sync to clock."));
|
||||||
basesink->have_newsegment = TRUE;
|
basesink->have_newsegment = TRUE;
|
||||||
/* this means this sink will not be able to sync to the clock */
|
/* this means this sink will not be able to sync to the clock */
|
||||||
|
|
|
@ -50,6 +50,7 @@
|
||||||
#include "gstbasesrc.h"
|
#include "gstbasesrc.h"
|
||||||
#include "gsttypefindhelper.h"
|
#include "gsttypefindhelper.h"
|
||||||
#include <gst/gstmarshal.h>
|
#include <gst/gstmarshal.h>
|
||||||
|
#include <gst/gst-i18n-lib.h>
|
||||||
|
|
||||||
#define DEFAULT_BLOCKSIZE 4096
|
#define DEFAULT_BLOCKSIZE 4096
|
||||||
#define DEFAULT_NUM_BUFFERS -1
|
#define DEFAULT_NUM_BUFFERS -1
|
||||||
|
@ -768,18 +769,17 @@ pause:
|
||||||
gst_pad_pause_task (pad);
|
gst_pad_pause_task (pad);
|
||||||
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
|
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
|
||||||
/* for fatal errors we post an error message */
|
/* for fatal errors we post an error message */
|
||||||
GST_ELEMENT_ERROR (src, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (src, STREAM, FAILED,
|
||||||
("streaming stopped, reason %s", gst_flow_get_name (ret)),
|
(_("Internal data flow error.")),
|
||||||
("streaming stopped, reason %s", gst_flow_get_name (ret)));
|
("streaming task paused, reason %s", gst_flow_get_name (ret)));
|
||||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
error:
|
error:
|
||||||
{
|
{
|
||||||
GST_ELEMENT_ERROR (src, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (src, STREAM, FAILED,
|
||||||
("internal: element returned NULL buffer"),
|
(_("Internal data flow error.")), ("element returned NULL buffer"));
|
||||||
("internal: element returned NULL buffer"));
|
|
||||||
gst_pad_pause_task (pad);
|
gst_pad_pause_task (pad);
|
||||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -161,16 +161,14 @@ _gst_stream_errors_init (void)
|
||||||
TABLE (t, STREAM, ENCODE, N_("Could not encode stream."));
|
TABLE (t, STREAM, ENCODE, N_("Could not encode stream."));
|
||||||
TABLE (t, STREAM, DEMUX, N_("Could not demultiplex stream."));
|
TABLE (t, STREAM, DEMUX, N_("Could not demultiplex stream."));
|
||||||
TABLE (t, STREAM, MUX, N_("Could not multiplex stream."));
|
TABLE (t, STREAM, MUX, N_("Could not multiplex stream."));
|
||||||
TABLE (t, STREAM, FORMAT, N_("Stream is of the wrong format."));
|
|
||||||
TABLE (t, STREAM, STOPPED, N_("Streaming stopped."));
|
|
||||||
|
|
||||||
return t;
|
return t;
|
||||||
}
|
}
|
||||||
|
|
||||||
QUARK_FUNC (core)
|
QUARK_FUNC (core);
|
||||||
QUARK_FUNC (library)
|
QUARK_FUNC (library);
|
||||||
QUARK_FUNC (resource)
|
QUARK_FUNC (resource);
|
||||||
QUARK_FUNC (stream)
|
QUARK_FUNC (stream);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gst_error_get_message:
|
* gst_error_get_message:
|
||||||
|
@ -182,7 +180,8 @@ QUARK_FUNC (core)
|
||||||
* Returns: a newly allocated string describing the error message in the
|
* Returns: a newly allocated string describing the error message in the
|
||||||
* current locale.
|
* current locale.
|
||||||
*/
|
*/
|
||||||
gchar *gst_error_get_message (GQuark domain, gint code)
|
gchar *
|
||||||
|
gst_error_get_message (GQuark domain, gint code)
|
||||||
{
|
{
|
||||||
static gchar **gst_core_errors = NULL;
|
static gchar **gst_core_errors = NULL;
|
||||||
static gchar **gst_library_errors = NULL;
|
static gchar **gst_library_errors = NULL;
|
||||||
|
|
|
@ -161,7 +161,6 @@ typedef enum
|
||||||
* @GST_STREAM_ERROR_MUX: used when muxing fails.
|
* @GST_STREAM_ERROR_MUX: used when muxing fails.
|
||||||
* @GST_STREAM_ERROR_FORMAT: used when the stream is of the wrong format
|
* @GST_STREAM_ERROR_FORMAT: used when the stream is of the wrong format
|
||||||
* (for example, wrong caps).
|
* (for example, wrong caps).
|
||||||
* @GST_STREAM_ERROR_STOPPED: Streaming stopped.
|
|
||||||
* @GST_STREAM_ERROR_NUM_ERRORS: the number of library error types.
|
* @GST_STREAM_ERROR_NUM_ERRORS: the number of library error types.
|
||||||
*
|
*
|
||||||
* Stream errors are for anything related to the stream being processed:
|
* Stream errors are for anything related to the stream being processed:
|
||||||
|
@ -181,7 +180,6 @@ typedef enum
|
||||||
GST_STREAM_ERROR_DEMUX,
|
GST_STREAM_ERROR_DEMUX,
|
||||||
GST_STREAM_ERROR_MUX,
|
GST_STREAM_ERROR_MUX,
|
||||||
GST_STREAM_ERROR_FORMAT,
|
GST_STREAM_ERROR_FORMAT,
|
||||||
GST_STREAM_ERROR_STOPPED,
|
|
||||||
GST_STREAM_ERROR_NUM_ERRORS
|
GST_STREAM_ERROR_NUM_ERRORS
|
||||||
} GstStreamError;
|
} GstStreamError;
|
||||||
|
|
||||||
|
|
|
@ -44,6 +44,7 @@
|
||||||
#include "gstinfo.h"
|
#include "gstinfo.h"
|
||||||
#include "gsterror.h"
|
#include "gsterror.h"
|
||||||
#include "gstutils.h"
|
#include "gstutils.h"
|
||||||
|
#include "gst-i18n-lib.h"
|
||||||
|
|
||||||
static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE ("sink",
|
static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE ("sink",
|
||||||
GST_PAD_SINK,
|
GST_PAD_SINK,
|
||||||
|
@ -819,8 +820,8 @@ restart:
|
||||||
|
|
||||||
queue->srcresult = result;
|
queue->srcresult = result;
|
||||||
if (GST_FLOW_IS_FATAL (result)) {
|
if (GST_FLOW_IS_FATAL (result)) {
|
||||||
GST_ELEMENT_ERROR (queue, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (queue, STREAM, FAILED,
|
||||||
("streaming stopped, reason %s", flowname),
|
(_("Internal data flow error.")),
|
||||||
("streaming stopped, reason %s", flowname));
|
("streaming stopped, reason %s", flowname));
|
||||||
gst_pad_push_event (queue->srcpad, gst_event_new_eos ());
|
gst_pad_push_event (queue->srcpad, gst_event_new_eos ());
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,6 +42,7 @@
|
||||||
|
|
||||||
#include "gstbasesink.h"
|
#include "gstbasesink.h"
|
||||||
#include <gst/gstmarshal.h>
|
#include <gst/gstmarshal.h>
|
||||||
|
#include <gst/gst-i18n-lib.h>
|
||||||
|
|
||||||
GST_DEBUG_CATEGORY_STATIC (gst_base_sink_debug);
|
GST_DEBUG_CATEGORY_STATIC (gst_base_sink_debug);
|
||||||
#define GST_CAT_DEFAULT gst_base_sink_debug
|
#define GST_CAT_DEFAULT gst_base_sink_debug
|
||||||
|
@ -622,8 +623,8 @@ gst_base_sink_handle_object (GstBaseSink * basesink, GstPad * pad,
|
||||||
GstBuffer *buf = GST_BUFFER (obj);
|
GstBuffer *buf = GST_BUFFER (obj);
|
||||||
|
|
||||||
if (!basesink->have_newsegment) {
|
if (!basesink->have_newsegment) {
|
||||||
GST_ELEMENT_WARNING (basesink, STREAM, STOPPED,
|
GST_ELEMENT_WARNING (basesink, STREAM, FAILED,
|
||||||
("Received buffer without a new-segment. Cannot sync to clock."),
|
(_("Internal data flow problem.")),
|
||||||
("Received buffer without a new-segment. Cannot sync to clock."));
|
("Received buffer without a new-segment. Cannot sync to clock."));
|
||||||
basesink->have_newsegment = TRUE;
|
basesink->have_newsegment = TRUE;
|
||||||
/* this means this sink will not be able to sync to the clock */
|
/* this means this sink will not be able to sync to the clock */
|
||||||
|
|
|
@ -50,6 +50,7 @@
|
||||||
#include "gstbasesrc.h"
|
#include "gstbasesrc.h"
|
||||||
#include "gsttypefindhelper.h"
|
#include "gsttypefindhelper.h"
|
||||||
#include <gst/gstmarshal.h>
|
#include <gst/gstmarshal.h>
|
||||||
|
#include <gst/gst-i18n-lib.h>
|
||||||
|
|
||||||
#define DEFAULT_BLOCKSIZE 4096
|
#define DEFAULT_BLOCKSIZE 4096
|
||||||
#define DEFAULT_NUM_BUFFERS -1
|
#define DEFAULT_NUM_BUFFERS -1
|
||||||
|
@ -768,18 +769,17 @@ pause:
|
||||||
gst_pad_pause_task (pad);
|
gst_pad_pause_task (pad);
|
||||||
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
|
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
|
||||||
/* for fatal errors we post an error message */
|
/* for fatal errors we post an error message */
|
||||||
GST_ELEMENT_ERROR (src, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (src, STREAM, FAILED,
|
||||||
("streaming stopped, reason %s", gst_flow_get_name (ret)),
|
(_("Internal data flow error.")),
|
||||||
("streaming stopped, reason %s", gst_flow_get_name (ret)));
|
("streaming task paused, reason %s", gst_flow_get_name (ret)));
|
||||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
error:
|
error:
|
||||||
{
|
{
|
||||||
GST_ELEMENT_ERROR (src, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (src, STREAM, FAILED,
|
||||||
("internal: element returned NULL buffer"),
|
(_("Internal data flow error.")), ("element returned NULL buffer"));
|
||||||
("internal: element returned NULL buffer"));
|
|
||||||
gst_pad_pause_task (pad);
|
gst_pad_pause_task (pad);
|
||||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -44,6 +44,7 @@
|
||||||
#include "gstinfo.h"
|
#include "gstinfo.h"
|
||||||
#include "gsterror.h"
|
#include "gsterror.h"
|
||||||
#include "gstutils.h"
|
#include "gstutils.h"
|
||||||
|
#include "gst-i18n-lib.h"
|
||||||
|
|
||||||
static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE ("sink",
|
static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE ("sink",
|
||||||
GST_PAD_SINK,
|
GST_PAD_SINK,
|
||||||
|
@ -819,8 +820,8 @@ restart:
|
||||||
|
|
||||||
queue->srcresult = result;
|
queue->srcresult = result;
|
||||||
if (GST_FLOW_IS_FATAL (result)) {
|
if (GST_FLOW_IS_FATAL (result)) {
|
||||||
GST_ELEMENT_ERROR (queue, STREAM, STOPPED,
|
GST_ELEMENT_ERROR (queue, STREAM, FAILED,
|
||||||
("streaming stopped, reason %s", flowname),
|
(_("Internal data flow error.")),
|
||||||
("streaming stopped, reason %s", flowname));
|
("streaming stopped, reason %s", flowname));
|
||||||
gst_pad_push_event (queue->srcpad, gst_event_new_eos ());
|
gst_pad_push_event (queue->srcpad, gst_event_new_eos ());
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,10 @@
|
||||||
gst/gst.c
|
gst/gst.c
|
||||||
gst/gstelement.c
|
gst/gstelement.c
|
||||||
gst/gsterror.c
|
gst/gsterror.c
|
||||||
|
gst/gstqueue.c
|
||||||
gst/gsttaglist.c
|
gst/gsttaglist.c
|
||||||
|
gst/base/gstbasesrc.c
|
||||||
|
gst/base/gstbasesink.c
|
||||||
gst/elements/gstfakesink.c
|
gst/elements/gstfakesink.c
|
||||||
gst/elements/gstfilesink.c
|
gst/elements/gstfilesink.c
|
||||||
gst/elements/gstfilesrc.c
|
gst/elements/gstfilesrc.c
|
||||||
|
|
Loading…
Reference in a new issue