[vlc-devel] commit: qt4: Use playlist_CurrentInput(). (Pierre d'Herbemont )

git version control git at videolan.org
Sat Jul 5 15:47:49 CEST 2008


vlc | branch: master | Pierre d'Herbemont <pdherbemont at videolan.org> | Sat Jul  5 15:15:19 2008 +0200| [c05f65e989890a59efcfe80402fad3574bbf4a13]

qt4: Use playlist_CurrentInput().

Should fix a race condition about freed input usage.

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

 modules/gui/qt4/input_manager.cpp |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/modules/gui/qt4/input_manager.cpp b/modules/gui/qt4/input_manager.cpp
index 2dfcf8d..b4b0a90 100644
--- a/modules/gui/qt4/input_manager.cpp
+++ b/modules/gui/qt4/input_manager.cpp
@@ -590,8 +590,9 @@ void MainInputManager::customEvent( QEvent *event )
     {
         /* we are working as a dialogs provider */
         playlist_t *p_playlist = pl_Yield( p_intf );
-        p_input = p_playlist->p_input;
+        p_input = playlist_CurrentInput( p_playlist );
         emit inputChanged( p_input );
+        vlc_object_release( p_input );
     }
 }
 




More information about the vlc-devel mailing list