summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/installationmanager.cpp6
-rw-r--r--src/installationmanager.h1
2 files changed, 6 insertions, 1 deletions
diff --git a/src/installationmanager.cpp b/src/installationmanager.cpp
index 5c8b6897..64e58358 100644
--- a/src/installationmanager.cpp
+++ b/src/installationmanager.cpp
@@ -451,7 +451,7 @@ void InstallationManager::updateProgressFile(QString const &fileName)
void InstallationManager::report7ZipError(QString const &errorMessage)
{
- reportError(errorMessage);
+ m_ErrorMessage = errorMessage;
m_ArchiveHandler->cancel();
}
@@ -608,7 +608,11 @@ bool InstallationManager::doInstall(GuessedValue<QString> &modName, QString game
} while (!future.isFinished());
if (!future.result()) {
if (m_ArchiveHandler->getLastError() == Archive::ERROR_EXTRACT_CANCELLED) {
+ if (!m_ErrorMessage.isEmpty()) {
+ throw MyException(QString("extracting failed (%1)").arg(m_ErrorMessage));
+ } else {
return false;
+ }
} else {
throw MyException(QString("extracting failed (%1)").arg(m_ArchiveHandler->getLastError()));
}
diff --git a/src/installationmanager.h b/src/installationmanager.h
index 5160d137..7c43b4e2 100644
--- a/src/installationmanager.h
+++ b/src/installationmanager.h
@@ -212,6 +212,7 @@ private:
Archive *m_ArchiveHandler;
QString m_CurrentFile;
+ QString m_ErrorMessage;
QProgressDialog *m_InstallationProgress { nullptr };
int m_Progress;