diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index 6b16ca452..30ede824f 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -192,12 +192,9 @@ MainWindow::~MainWindow() void MainWindow::HandleCLIParams(const QStringList ¶ms) { if (params.contains("-p")) { - QString projFile; const int ind = params.indexOf("-p"); if ((ind + 1) < params.length()) - projFile = params[ind + 1]; - - LoadProjectFile(projFile); + LoadProjectFile(params[ind + 1]); } else DoCheckFiles(params); }