summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/documentlist.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/core/launcher/documentlist.cpp b/core/launcher/documentlist.cpp
index 39dc7c9..63f853e 100644
--- a/core/launcher/documentlist.cpp
+++ b/core/launcher/documentlist.cpp
@@ -438,12 +438,16 @@ void DocumentListPrivate::appendDocpath(FileSystem*fs)
Mediadlg dlg(fs);
if (QDialog::Accepted != QPEApplication::execDialog( &dlg )) {
return;
}
}
Config conf(f.filePath(), Config::File );
+ conf.setGroup("main");
+ if (!conf.readBoolEntry("check",false)) {
+ return;
+ }
conf.setGroup("subdirs");
bool read_all = conf.readBoolEntry("wholemedia",true);
if (read_all) {
docPaths+=fs->path();
return;
}
@@ -557,12 +561,15 @@ const QString DocumentListPrivate::nextFile()
searchDepth = 0;
}
}
}
const QFileInfoList *fil = lists[searchDepth];
+ if (!fil) {
+ return QString::null;
+ }
QFileInfoList *fl = (QFileInfoList *)fil;
unsigned int pos = listPositions[searchDepth];
if ( pos >= fl->count() ) {
// go up a depth
delete listDirs[searchDepth];