]> git.sesse.net Git - vlc/commitdiff
playlist: modified playlist_NodeCreate()
authorSebastian Birk <sebastian.birk@googlemail.com>
Wed, 2 Jun 2010 09:19:06 +0000 (11:19 +0200)
committerJean-Baptiste Kempf <jb@videolan.org>
Wed, 2 Jun 2010 09:19:41 +0000 (11:19 +0200)
The passed flags in the variable i_flags are now applied to the new node.
This solves bug ticket #3690, where it was possible to delete the "Playlist" and
"Media Library" nodes, since the read-only flag was not set for them.

src/playlist/tree.c

index eae53bde2ce57c11a3f009d64c08d71773fdc1be..152af3fdcc783c248a35391f31862110a2cac624 100644 (file)
@@ -85,6 +85,9 @@ playlist_item_t * playlist_NodeCreate( playlist_t *p_playlist,
     playlist_SendAddNotify( p_playlist, p_item->i_id,
                             p_parent ? p_parent->i_id : -1,
                             !( i_flags & PLAYLIST_NO_REBUILD ));
+
+    p_item->i_flags |= i_flags
+
     return p_item;
 }