summaryrefslogtreecommitdiff
path: root/gst/mpeg4videoparse
diff options
context:
space:
mode:
authorArnout Vandecappelle <arnout@mind.be>2009-05-05 16:54:39 +0200
committerWim Taymans <wim.taymans@collabora.co.uk>2009-05-05 16:54:39 +0200
commit9542d9e2513c0d88a8de65c7585e0d81b7249dda (patch)
tree0d59820b34a9e0a96b48be7f85514ab2b3149a35 /gst/mpeg4videoparse
parent46139253bcb1ddc32fc8987c194c40d9c622e993 (diff)
mpeg4videoparse: don't leak the config data
Clear the config data when going to READY or when disposed. Fixes #581427
Diffstat (limited to 'gst/mpeg4videoparse')
-rw-r--r--gst/mpeg4videoparse/mpeg4videoparse.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gst/mpeg4videoparse/mpeg4videoparse.c b/gst/mpeg4videoparse/mpeg4videoparse.c
index 1efa28bee..e0e28d0cd 100644
--- a/gst/mpeg4videoparse/mpeg4videoparse.c
+++ b/gst/mpeg4videoparse/mpeg4videoparse.c
@@ -726,6 +726,10 @@ gst_mpeg4vparse_cleanup (GstMpeg4VParse * parse)
if (parse->adapter) {
gst_adapter_clear (parse->adapter);
}
+ if (parse->config != NULL) {
+ gst_buffer_unref (parse->config);
+ parse->config = NULL;
+ }
parse->state = PARSE_NEED_START;
parse->have_config = FALSE;
@@ -760,6 +764,10 @@ gst_mpeg4vparse_dispose (GObject * object)
g_object_unref (parse->adapter);
parse->adapter = NULL;
}
+ if (parse->config != NULL) {
+ gst_buffer_unref (parse->config);
+ parse->config = NULL;
+ }
GST_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
}