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
@ -726,6 +726,10 @@ gst_mpeg4vparse_cleanup (GstMpeg4VParse * parse)
|
|||||||
if (parse->adapter) {
|
if (parse->adapter) {
|
||||||
gst_adapter_clear (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->state = PARSE_NEED_START;
|
||||||
parse->have_config = FALSE;
|
parse->have_config = FALSE;
|
||||||
@ -760,6 +764,10 @@ gst_mpeg4vparse_dispose (GObject * object)
|
|||||||
g_object_unref (parse->adapter);
|
g_object_unref (parse->adapter);
|
||||||
parse->adapter = NULL;
|
parse->adapter = NULL;
|
||||||
}
|
}
|
||||||
|
if (parse->config != NULL) {
|
||||||
|
gst_buffer_unref (parse->config);
|
||||||
|
parse->config = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
GST_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
|
GST_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user