[vlc-commits] Qt4: remove useless checks

Rémi Denis-Courmont git at videolan.org
Thu Feb 5 21:41:00 CET 2015


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Feb  5 20:56:47 2015 +0200| [2a7f208bd5d16606b759177fd06e2f0afcad3666] | committer: Rémi Denis-Courmont

Qt4: remove useless checks

An input thread always has a valid input item even if it is dead.
If not, the code would have had a ToCToU bug anyway.

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

 modules/gui/qt4/components/playlist/playlist_model.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/gui/qt4/components/playlist/playlist_model.cpp b/modules/gui/qt4/components/playlist/playlist_model.cpp
index b5d68c4..1872ce3 100644
--- a/modules/gui/qt4/components/playlist/playlist_model.cpp
+++ b/modules/gui/qt4/components/playlist/playlist_model.cpp
@@ -563,7 +563,7 @@ void PLModel::processInputItemUpdate( )
     input_thread_t *p_input = THEMIM->getInput();
     if( !p_input ) return;
 
-    if( p_input && !( p_input->b_dead || !vlc_object_alive( p_input ) ) )
+    if( p_input )
     {
         PLItem *item = findByInputId( rootItem, input_GetItem( p_input )->i_id );
         if( item ) emit currentIndexChanged( index( item, 0 ) );



More information about the vlc-commits mailing list