mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-14 03:54:11 +00:00
gst/playback/gstdecodebin2.c: Dont leak ghostpad. Fixes #475451.
Original commit message from CVS: * gst/playback/gstdecodebin2.c: Dont leak ghostpad. Fixes #475451.
This commit is contained in:
parent
905945738d
commit
1c2fae7f8b
2 changed files with 15 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2007-11-09 Stefan Kost <ensonic@users.sf.net>
|
||||
|
||||
* gst/playback/gstdecodebin2.c:
|
||||
Dont leak ghostpad. Fixes #475451.
|
||||
|
||||
2007-11-09 Wim Taymans <wim.taymans@gmail.com>
|
||||
|
||||
* docs/design/design-decodebin.txt:
|
||||
|
|
|
@ -2097,6 +2097,16 @@ gst_decode_group_free (GstDecodeGroup * group)
|
|||
GST_LOG ("group %p", group);
|
||||
|
||||
GROUP_MUTEX_LOCK (group);
|
||||
|
||||
/* free ghost pads */
|
||||
if (group == group->dbin->activegroup) {
|
||||
for (tmp = group->ghosts; tmp; tmp = g_list_next (tmp))
|
||||
gst_element_remove_pad (GST_ELEMENT (group->dbin), (GstPad *) tmp->data);
|
||||
|
||||
g_list_free (group->ghosts);
|
||||
group->ghosts = NULL;
|
||||
}
|
||||
|
||||
/* Clear all GstDecodePad */
|
||||
for (tmp = group->endpads; tmp; tmp = g_list_next (tmp)) {
|
||||
GstDecodePad *dpad = (GstDecodePad *) tmp->data;
|
||||
|
|
Loading…
Reference in a new issue