[vlc-devel] commit: qt4: add forgotten check so we don' t try to get stuff from NULL-pointer (Ilkka Ollakka )
git version control
git at videolan.org
Sun Aug 16 14:21:37 CEST 2009
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Sun Aug 16 15:20:18 2009 +0300| [2c3bac1eabfef3ba0db6a7f1453d4cd15f246037] | committer: Ilkka Ollakka
qt4: add forgotten check so we don't try to get stuff from NULL-pointer
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=2c3bac1eabfef3ba0db6a7f1453d4cd15f246037
---
.../gui/qt4/components/playlist/playlist_model.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/modules/gui/qt4/components/playlist/playlist_model.cpp b/modules/gui/qt4/components/playlist/playlist_model.cpp
index 6544769..8b3606b 100644
--- a/modules/gui/qt4/components/playlist/playlist_model.cpp
+++ b/modules/gui/qt4/components/playlist/playlist_model.cpp
@@ -282,7 +282,7 @@ bool PLModel::dropMimeData( const QMimeData *data, Qt::DropAction action,
void PLModel::removeItem( int i_id )
{
PLItem *item = FindById( rootItem, i_id );
- if( currentItem && currentItem->p_input == item->p_input ) currentItem = NULL;
+ if( currentItem && item && currentItem->p_input == item->p_input ) currentItem = NULL;
if( item ) item->remove( item );
}
More information about the vlc-devel
mailing list