check/Makefile.am: Enable valgrind check.

Original commit message from CVS:
* check/Makefile.am:
Enable valgrind check.

* gst/elements/gstfakesrc.c: (gst_fake_src_alloc_parent),
(gst_fake_src_alloc_buffer):
Fix memleak.
This commit is contained in:
Wim Taymans 2005-11-16 17:35:07 +00:00
parent f2646a0fc9
commit 578f2ae633
5 changed files with 17 additions and 2 deletions

View file

@ -1,3 +1,12 @@
2005-11-16 Wim Taymans <wim@fluendo.com>
* check/Makefile.am:
Enable valgrind check.
* gst/elements/gstfakesrc.c: (gst_fake_src_alloc_parent),
(gst_fake_src_alloc_buffer):
Fix memleak.
2005-11-16 Wim Taymans <wim@fluendo.com>
* gst/net/gstnettimeprovider.c: (gst_net_time_provider_finalize):

View file

@ -86,7 +86,6 @@ net_gstnettimeprovider_LDADD = \
# valgrind testing
# these just need valgrind fixing, period
VALGRIND_TO_FIX = \
elements/fakesrc \
gst/gstevent \
gst-libs/controller \
pipelines/simple_launch_lines

View file

@ -382,6 +382,7 @@ gst_fake_src_alloc_parent (GstFakeSrc * src)
buf = gst_buffer_new ();
GST_BUFFER_DATA (buf) = g_malloc (src->parentsize);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
GST_BUFFER_SIZE (buf) = src->parentsize;
src->parent = buf;
@ -586,15 +587,18 @@ gst_fake_src_alloc_buffer (GstFakeSrc * src, guint size)
switch (src->filltype) {
case FAKE_SRC_FILLTYPE_NOTHING:
GST_BUFFER_DATA (buf) = g_malloc (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
break;
case FAKE_SRC_FILLTYPE_NULL:
GST_BUFFER_DATA (buf) = g_malloc0 (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
break;
case FAKE_SRC_FILLTYPE_RANDOM:
case FAKE_SRC_FILLTYPE_PATTERN:
case FAKE_SRC_FILLTYPE_PATTERN_CONT:
default:
GST_BUFFER_DATA (buf) = g_malloc (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
gst_fake_src_prepare_buffer (src, buf);
break;
}

View file

@ -382,6 +382,7 @@ gst_fake_src_alloc_parent (GstFakeSrc * src)
buf = gst_buffer_new ();
GST_BUFFER_DATA (buf) = g_malloc (src->parentsize);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
GST_BUFFER_SIZE (buf) = src->parentsize;
src->parent = buf;
@ -586,15 +587,18 @@ gst_fake_src_alloc_buffer (GstFakeSrc * src, guint size)
switch (src->filltype) {
case FAKE_SRC_FILLTYPE_NOTHING:
GST_BUFFER_DATA (buf) = g_malloc (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
break;
case FAKE_SRC_FILLTYPE_NULL:
GST_BUFFER_DATA (buf) = g_malloc0 (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
break;
case FAKE_SRC_FILLTYPE_RANDOM:
case FAKE_SRC_FILLTYPE_PATTERN:
case FAKE_SRC_FILLTYPE_PATTERN_CONT:
default:
GST_BUFFER_DATA (buf) = g_malloc (size);
GST_BUFFER_MALLOCDATA (buf) = GST_BUFFER_DATA (buf);
gst_fake_src_prepare_buffer (src, buf);
break;
}

View file

@ -86,7 +86,6 @@ net_gstnettimeprovider_LDADD = \
# valgrind testing
# these just need valgrind fixing, period
VALGRIND_TO_FIX = \
elements/fakesrc \
gst/gstevent \
gst-libs/controller \
pipelines/simple_launch_lines