From e7fcaab6ff49da28d84ba319ef7f75afd0a90b41 Mon Sep 17 00:00:00 2001 From: Ilkka Ollakka Date: Wed, 23 Jun 2010 14:37:30 +0300 Subject: [PATCH] Qt4: add check if current isValid() --- 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 2c1fb7644e..2e27bc015b 100644 --- a/modules/gui/qt4/components/playlist/playlist_model.cpp +++ b/modules/gui/qt4/components/playlist/playlist_model.cpp @@ -391,7 +391,7 @@ bool PLModel::isParent( const QModelIndex &index, const QModelIndex ¤t ) c if( index == current ) return true; - if( !current.parent().isValid() ) + if( !current.isValid() || !current.parent().isValid() ) return false; return isParent( index, current.parent() ); -- 2.39.2