From c4dd23abb7a37531040d6348c491dc868919013c Mon Sep 17 00:00:00 2001 From: isanae <14251494+isanae@users.noreply.github.com> Date: Fri, 4 Oct 2019 09:40:37 -0400 Subject: added error messages to FileRenamer and a few more fixes for shell functions changing names --- src/selfupdater.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/selfupdater.cpp') diff --git a/src/selfupdater.cpp b/src/selfupdater.cpp index 8887927a..5a70568e 100644 --- a/src/selfupdater.cpp +++ b/src/selfupdater.cpp @@ -341,11 +341,14 @@ void SelfUpdater::downloadCancel() void SelfUpdater::installUpdate() { const QString parameters = "/DIR=\"" + qApp->applicationDirPath() + "\" "; + const auto r = shell::Execute(m_UpdateFile.fileName(), parameters); - if (shell::Execute(m_UpdateFile.fileName(), parameters)) { + if (r.success()) { QCoreApplication::quit(); } else { - reportError(tr("Failed to start %1").arg(m_UpdateFile.fileName())); + reportError(tr("Failed to start %1: %2") + .arg(m_UpdateFile.fileName()) + .arg(r.toString())); } m_UpdateFile.remove(); -- cgit v1.3.1