We need to store the new GList. Else, this causes problems if we remove the first entry from the list (unreferenced p...

Original commit message from CVS:
We need to store the new GList. Else, this causes problems if we remove the first entry from the list (unreferenced pointer). Also, we need to destroy the unused entry afterwards (memleak).
This commit is contained in:
Ronald S. Bultje 2003-10-20 08:22:19 +00:00
parent 9e9344fe94
commit 2021fd636c

View file

@ -969,7 +969,8 @@ gst_props_remove_entry_by_id (GstProps *props, GQuark propid)
if (lentry->propid == propid) {
found = TRUE;
g_list_delete_link (props->properties, current);
props->properties = g_list_delete_link (props->properties, current);
gst_props_entry_destroy (lentry);
}
else if (GST_PROPS_ENTRY_IS_VARIABLE (lentry)) {
GST_PROPS_FLAG_UNSET (props, GST_PROPS_FIXED);