mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
ext/amrwb/gstamrwbparse.c: Don't leak the adapter.
Original commit message from CVS: * ext/amrwb/gstamrwbparse.c: Don't leak the adapter.
This commit is contained in:
parent
e221638fdd
commit
03afa9b296
2 changed files with 24 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2007-08-17 Stefan Kost <ensonic@users.sf.net>
|
||||||
|
|
||||||
|
* ext/amrwb/gstamrwbparse.c:
|
||||||
|
Don't leak the adapter.
|
||||||
|
|
||||||
2007-08-16 Sebastian Dröge <slomo@circular-chaos.org>
|
2007-08-16 Sebastian Dröge <slomo@circular-chaos.org>
|
||||||
|
|
||||||
* gst/filter/gstbpwsinc.c: (gst_bpwsinc_class_init),
|
* gst/filter/gstbpwsinc.c: (gst_bpwsinc_class_init),
|
||||||
|
|
|
@ -75,6 +75,8 @@ static gboolean gst_amrwbparse_sink_activate_pull (GstPad * sinkpad,
|
||||||
static GstStateChangeReturn gst_amrwbparse_state_change (GstElement * element,
|
static GstStateChangeReturn gst_amrwbparse_state_change (GstElement * element,
|
||||||
GstStateChange transition);
|
GstStateChange transition);
|
||||||
|
|
||||||
|
static void gst_amrwbparse_finalize (GObject * object);
|
||||||
|
|
||||||
#define _do_init(bla) \
|
#define _do_init(bla) \
|
||||||
GST_DEBUG_CATEGORY_INIT (gst_amrwbparse_debug, "amrwbparse", 0, "AMR-WB audio stream parser");
|
GST_DEBUG_CATEGORY_INIT (gst_amrwbparse_debug, "amrwbparse", 0, "AMR-WB audio stream parser");
|
||||||
|
|
||||||
|
@ -102,8 +104,11 @@ gst_amrwbparse_base_init (gpointer klass)
|
||||||
static void
|
static void
|
||||||
gst_amrwbparse_class_init (GstAmrwbParseClass * klass)
|
gst_amrwbparse_class_init (GstAmrwbParseClass * klass)
|
||||||
{
|
{
|
||||||
|
GObjectClass *object_class = G_OBJECT_CLASS (klass);
|
||||||
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
|
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
|
||||||
|
|
||||||
|
object_class->finalize = gst_amrwbparse_finalize;
|
||||||
|
|
||||||
element_class->change_state = GST_DEBUG_FUNCPTR (gst_amrwbparse_state_change);
|
element_class->change_state = GST_DEBUG_FUNCPTR (gst_amrwbparse_state_change);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -137,6 +142,20 @@ gst_amrwbparse_init (GstAmrwbParse * amrwbparse, GstAmrwbParseClass * klass)
|
||||||
amrwbparse->ts = 0;
|
amrwbparse->ts = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
gst_amrwbparse_finalize (GObject * object)
|
||||||
|
{
|
||||||
|
GstAmrwbParse *amrwbparse;
|
||||||
|
|
||||||
|
amrwbparse = GST_AMRWBPARSE (object);
|
||||||
|
|
||||||
|
gst_adapter_clear (amrwbparse->adapter);
|
||||||
|
g_object_unref (amrwbparse->adapter);
|
||||||
|
|
||||||
|
G_OBJECT_CLASS (parent_class)->finalize (object);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static const GstQueryType *
|
static const GstQueryType *
|
||||||
gst_amrwbparse_querytypes (GstPad * pad)
|
gst_amrwbparse_querytypes (GstPad * pad)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue