mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-10 01:15:39 +00:00
decodebin3: Free main input even if it is not part of the list of inputs
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8216>
This commit is contained in:
parent
126d6f0815
commit
f0a8938133
1 changed files with 10 additions and 1 deletions
|
@ -794,8 +794,17 @@ gst_decodebin3_dispose (GObject * object)
|
||||||
g_mutex_unlock (&dbin->factories_lock);
|
g_mutex_unlock (&dbin->factories_lock);
|
||||||
|
|
||||||
INPUT_LOCK (dbin);
|
INPUT_LOCK (dbin);
|
||||||
g_list_free_full (dbin->inputs, (GDestroyNotify) gst_decodebin_input_free);
|
while (dbin->inputs) {
|
||||||
|
DecodebinInput *input = dbin->inputs->data;
|
||||||
|
if (input->is_main)
|
||||||
|
dbin->main_input = NULL;
|
||||||
|
gst_decodebin_input_free (input);
|
||||||
|
|
||||||
|
dbin->inputs = g_list_delete_link (dbin->inputs, dbin->inputs);
|
||||||
|
}
|
||||||
dbin->inputs = NULL;
|
dbin->inputs = NULL;
|
||||||
|
if (dbin->main_input)
|
||||||
|
gst_decodebin_input_free (dbin->main_input);
|
||||||
dbin->main_input = NULL;
|
dbin->main_input = NULL;
|
||||||
INPUT_UNLOCK (dbin);
|
INPUT_UNLOCK (dbin);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue