mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-28 19:20:35 +00:00
mpeg4videoparse: don't leak the config data
Clear the config data when going to READY or when disposed. Fixes #581427
This commit is contained in:
parent
46139253bc
commit
9542d9e251
1 changed files with 8 additions and 0 deletions
|
@ -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));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue