Commit e8a69299 authored by Stephan Kulow's avatar Stephan Kulow
Browse files

if item can be 0, then you don't want to crash (CID 3793)

svn path=/trunk/KDE/kdemultimedia/juk/; revision=763703
parent 60b051cc
...@@ -301,14 +301,16 @@ void PlaylistBox::remove() ...@@ -301,14 +301,16 @@ void PlaylistBox::remove()
QStringList names; QStringList names;
foreach(Item *item, items) { foreach(Item *item, items) {
if(item && item->playlist() && if(item && item->playlist())
!item->playlist()->fileName().isEmpty() &&
QFileInfo(item->playlist()->fileName()).exists())
{ {
if (!item->playlist()->fileName().isEmpty() &&
QFileInfo(item->playlist()->fileName()).exists())
{
files.append(item->playlist()->fileName()); files.append(item->playlist()->fileName());
} }
names.append(item->playlist()->name()); names.append(item->playlist()->name());
}
} }
if(!files.isEmpty()) { if(!files.isEmpty()) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment