Fix crash when no modules are available

pull/1/head
Timothy Pearson 12 years ago
parent 053af2ec36
commit 2348e07447

@ -28,7 +28,7 @@
#include "moduleiconitem.h"
KcmSearch::KcmSearch( TQPtrList<ModulesView> *moduleViewList, TQWidget *parent, const char *name )
: KIconViewSearchLine(parent, moduleViewList->at(0)->groups[0], name){
: KIconViewSearchLine(parent, (moduleViewList->at(0))?moduleViewList->at(0)->groups[0]:NULL, name){
this->moduleViewList = moduleViewList;
}

@ -180,7 +180,9 @@ void MainWindow::buildActions()
kdDebug() << "relpath is :" << group->relPath() << endl;
}
}
pageActions.at(0)->setChecked(true);
if (pageActions.at(0)) {
pageActions.at(0)->setChecked(true);
}
}
void MainWindow::aboutCurrentModule()

Loading…
Cancel
Save