mirror of
https://github.com/Rafostar/clapper.git
synced 2026-01-17 17:20:14 +01:00
clapper: Fix media items leak when parsing URI list
Unlike other array containers, GListStore append function refs object internally, so unref afterwards is needed.
This commit is contained in:
@@ -260,8 +260,10 @@ _parse_uri_list (ClapperPlaylistDemux *self, GUri *uri, GstBuffer *buffer,
|
||||
break;
|
||||
}
|
||||
|
||||
if (G_LIKELY (item != NULL))
|
||||
if (G_LIKELY (item != NULL)) {
|
||||
g_list_store_append (playlist, (GObject *) item);
|
||||
gst_object_unref (item);
|
||||
}
|
||||
|
||||
/* Advance to the next line */
|
||||
ptr = nl ? (nl + 1) : end;
|
||||
|
||||
Reference in New Issue
Block a user