[vlc-devel] commit: qt4: Forgotten lock. Reported by ahoka. (Pierre d'Herbemont )

git version control git at videolan.org
Wed Jul 16 23:44:08 CEST 2008


vlc | branch: master | Pierre d'Herbemont <pdherbemont at videolan.org> | Wed Jul 16 23:46:30 2008 +0200| [db3f5756103f3103b28ca0554c59461602a75ccf]

qt4: Forgotten lock. Reported by ahoka.

Anyway this is broken, qt4 shouldn't assume that the playlist_item_t can't be deleted. We need to implement refcounting here, or a sound garbage collection. Refcounting would be safer.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=db3f5756103f3103b28ca0554c59461602a75ccf
---

 modules/gui/qt4/components/playlist/playlist.cpp |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/modules/gui/qt4/components/playlist/playlist.cpp b/modules/gui/qt4/components/playlist/playlist.cpp
index fcc6d2d..1403fc0 100644
--- a/modules/gui/qt4/components/playlist/playlist.cpp
+++ b/modules/gui/qt4/components/playlist/playlist.cpp
@@ -79,8 +79,10 @@ PlaylistWidget::PlaylistWidget( intf_thread_t *_p_i,
     leftW->addWidget( artContainer );
 
     /* Initialisation of the playlist */
+    PL_LOCK;
     playlist_item_t *p_root =
                   playlist_GetPreferredNode( THEPL, THEPL->p_local_category );
+    PL_UNLOCK;
 
     rightPanel = new StandardPLPanel( this, p_intf, THEPL, p_root );
 




More information about the vlc-devel mailing list