diff options
-rw-r--r-- | src/vsession.cpp | 5 | ||||
-rw-r--r-- | src/xsession.cpp | 5 |
2 files changed, 2 insertions, 8 deletions
diff --git a/src/vsession.cpp b/src/vsession.cpp index b86f314..79ef929 100644 --- a/src/vsession.cpp +++ b/src/vsession.cpp @@ -275,10 +275,7 @@ bool VSession::run() const { QObject::connect(&_process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), QApplication::instance(), &QCoreApplication::quit); _process.start(Config::get(Config::RUNSCRIPT), QStringList(tmpFileName)); _process.waitForStarted(10); - if (_process.state() == QProcess::Starting || _process.state() == QProcess::Running) - return true; - else - return false; + return _process.state() == QProcess::Starting || _process.state() == QProcess::Running; } int VSession::type() const { diff --git a/src/xsession.cpp b/src/xsession.cpp index d2e8cfe..05f4d38 100644 --- a/src/xsession.cpp +++ b/src/xsession.cpp @@ -159,10 +159,7 @@ QIcon XSession::icon() const { bool XSession::run() const { _process->start(this->exec_); QObject::connect(_process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), QApplication::instance(), &QCoreApplication::quit); - if (_process->state() == QProcess::Starting || _process->state() == QProcess::Running) - return true; - else - return false; + return _process->state() == QProcess::Starting || _process->state() == QProcess::Running; } int XSession::type() const { |