[vlc-devel] [PATCH] playlist: modified playlist_NodeCreate()

Sebastian Birk sebastian.birk at googlemail.com
Tue Jun 1 00:18:03 CEST 2010


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 |    3 +++
1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/playlist/tree.c b/src/playlist/tree.c
index eae53bd..e7fdebe 100644
--- a/src/playlist/tree.c
+++ b/src/playlist/tree.c
@@ -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;
}

-- 
1.7.1

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 203 bytes
Desc: Signierter Teil der Nachricht
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20100601/80ec0933/attachment.sig>


More information about the vlc-devel mailing list