Fix leaks some more.

Original commit message from CVS:
* ext/amrnb/amrnbdec.c: (gst_amrnbdec_init):
* gst/ac3parse/gstac3parse.c: (gst_ac3parse_init):
* gst/asfdemux/gstasfmux.c: (gst_asfmux_init):
* gst/dvdlpcmdec/gstdvdlpcmdec.c: (gst_dvdlpcmdec_init):
* gst/dvdsub/gstdvdsubdec.c: (gst_dvd_sub_dec_init):
* gst/iec958/ac3iec.c: (ac3iec_init):
* gst/mpegstream/gstrfc2250enc.c: (gst_rfc2250_enc_init):
Fix leaks some more.
This commit is contained in:
Edward Hervey 2007-06-22 10:57:06 +00:00
parent 33e97185f5
commit f4f98ea80b
8 changed files with 23 additions and 29 deletions

View file

@ -1,3 +1,14 @@
2007-06-22 Edward Hervey <edward@fluendo.com>
* ext/amrnb/amrnbdec.c: (gst_amrnbdec_init):
* gst/ac3parse/gstac3parse.c: (gst_ac3parse_init):
* gst/asfdemux/gstasfmux.c: (gst_asfmux_init):
* gst/dvdlpcmdec/gstdvdlpcmdec.c: (gst_dvdlpcmdec_init):
* gst/dvdsub/gstdvdsubdec.c: (gst_dvd_sub_dec_init):
* gst/iec958/ac3iec.c: (ac3iec_init):
* gst/mpegstream/gstrfc2250enc.c: (gst_rfc2250_enc_init):
Fix leaks some more.
2007-06-21 Edward Hervey <edward@fluendo.com>
* gst/mpegaudioparse/gstmpegaudioparse.c: (gst_mp3parse_init):

View file

@ -93,18 +93,14 @@ static void
gst_amrnbdec_init (GstAmrnbDec * amrnbdec, GstAmrnbDecClass * klass)
{
/* create the sink pad */
amrnbdec->sinkpad =
gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
"sink");
amrnbdec->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_setcaps_function (amrnbdec->sinkpad, gst_amrnbdec_setcaps);
gst_pad_set_event_function (amrnbdec->sinkpad, gst_amrnbdec_event);
gst_pad_set_chain_function (amrnbdec->sinkpad, gst_amrnbdec_chain);
gst_element_add_pad (GST_ELEMENT (amrnbdec), amrnbdec->sinkpad);
/* create the src pad */
amrnbdec->srcpad =
gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
"src");
amrnbdec->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_use_fixed_caps (amrnbdec->srcpad);
gst_element_add_pad (GST_ELEMENT (amrnbdec), amrnbdec->srcpad);

View file

@ -183,14 +183,12 @@ static void
gst_ac3parse_init (GstAc3Parse * ac3parse)
{
ac3parse->sinkpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&gst_ac3parse_sink_template), "sink");
gst_pad_new_from_static_template (&gst_ac3parse_sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (ac3parse), ac3parse->sinkpad);
gst_pad_set_chain_function (ac3parse->sinkpad, gst_ac3parse_chain);
ac3parse->srcpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&gst_ac3parse_src_template), "src");
gst_pad_new_from_static_template (&gst_ac3parse_src_template, "src");
gst_pad_use_explicit_caps (ac3parse->srcpad);
gst_element_add_pad (GST_ELEMENT (ac3parse), ac3parse->srcpad);

View file

@ -236,8 +236,7 @@ gst_asfmux_init (GstAsfMux * asfmux)
gint n;
asfmux->srcpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&gst_asfmux_src_template), "src");
gst_pad_new_from_static_template (&gst_asfmux_src_template, "src");
gst_element_add_pad (GST_ELEMENT (asfmux), asfmux->srcpad);
GST_OBJECT_FLAG_SET (GST_ELEMENT (asfmux), GST_ELEMENT_EVENT_AWARE);

View file

@ -162,15 +162,13 @@ static void
gst_dvdlpcmdec_init (GstDvdLpcmDec * dvdlpcmdec)
{
dvdlpcmdec->sinkpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&gst_dvdlpcmdec_sink_template), "sink");
gst_pad_new_from_static_template (&gst_dvdlpcmdec_sink_template, "sink");
gst_pad_set_setcaps_function (dvdlpcmdec->sinkpad, gst_dvdlpcmdec_setcaps);
gst_pad_set_event_function (dvdlpcmdec->sinkpad, dvdlpcmdec_sink_event);
gst_element_add_pad (GST_ELEMENT (dvdlpcmdec), dvdlpcmdec->sinkpad);
dvdlpcmdec->srcpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&gst_dvdlpcmdec_src_template), "src");
gst_pad_new_from_static_template (&gst_dvdlpcmdec_src_template, "src");
gst_pad_use_fixed_caps (dvdlpcmdec->srcpad);
gst_element_add_pad (GST_ELEMENT (dvdlpcmdec), dvdlpcmdec->srcpad);

View file

@ -130,9 +130,7 @@ gst_dvd_sub_dec_init (GstDvdSubDec * dec, GstDvdSubDecClass * klass)
{
GstPadTemplate *tmpl;
dec->sinkpad =
gst_pad_new_from_template (gst_static_pad_template_get
(&subtitle_template), "sink");
dec->sinkpad = gst_pad_new_from_static_template (&subtitle_template, "sink");
gst_pad_set_chain_function (dec->sinkpad,
GST_DEBUG_FUNCPTR (gst_dvd_sub_dec_chain));
gst_pad_set_event_function (dec->sinkpad,

View file

@ -177,15 +177,12 @@ static void
ac3iec_init (AC3IEC * ac3iec)
{
ac3iec->sink =
gst_pad_new_from_template (gst_static_pad_template_get
(&ac3iec_sink_template), "sink");
gst_pad_new_from_static_template (&ac3iec_sink_template, "sink");
gst_pad_set_setcaps_function (ac3iec->sink, ac3iec_setcaps);
gst_pad_set_chain_function (ac3iec->sink, ac3iec_chain_dvd);
gst_element_add_pad (GST_ELEMENT (ac3iec), ac3iec->sink);
ac3iec->src =
gst_pad_new_from_template (gst_static_pad_template_get
(&ac3iec_src_template), "src");
ac3iec->src = gst_pad_new_from_static_template (&ac3iec_src_template, "src");
gst_pad_use_fixed_caps (ac3iec->src);
gst_element_add_pad (GST_ELEMENT (ac3iec), ac3iec->src);

View file

@ -142,14 +142,11 @@ static void
gst_rfc2250_enc_init (GstRFC2250Enc * rfc2250_enc)
{
rfc2250_enc->sinkpad =
gst_pad_new_from_template (gst_static_pad_template_get (&sink_factory),
"sink");
gst_pad_new_from_static_template (&sink_factory, "sink");
gst_element_add_pad (GST_ELEMENT (rfc2250_enc), rfc2250_enc->sinkpad);
gst_element_set_loop_function (GST_ELEMENT (rfc2250_enc),
gst_rfc2250_enc_loop);
rfc2250_enc->srcpad =
gst_pad_new_from_template (gst_static_pad_template_get (&src_factory),
"src");
rfc2250_enc->srcpad = gst_pad_new_from_static_template (&src_factory, "src");
gst_element_add_pad (GST_ELEMENT (rfc2250_enc), rfc2250_enc->srcpad);
/* initialize parser state */