summaryrefslogtreecommitdiffstats
path: root/src/libs/installer/downloadfiletask.cpp
diff options
context:
space:
mode:
authorKatja Marttila <katja.marttila@qt.io>2018-05-14 14:58:25 +0300
committerKatja Marttila <katja.marttila@qt.io>2018-06-04 03:14:49 +0000
commit83cc3b6b88e40353cd0e03e88a6fe1abeba038d5 (patch)
tree867f6909d05f49c3eb0b1825d20002f057b916a0 /src/libs/installer/downloadfiletask.cpp
parent88d85a78949194aafa67340d3afdbc90594f9064 (diff)
Allow install other components if sha mismatches in metadata
Expanding commit "Add attribute to mark parts of install tree unstable." This change will allow installing other components if some component has sha mismatch. Change-Id: I61202da95dc07ca3f1fe931cfe1fbbb053596f42 Reviewed-by: Iikka Eklund <iikka.eklund@qt.io>
Diffstat (limited to 'src/libs/installer/downloadfiletask.cpp')
-rw-r--r--src/libs/installer/downloadfiletask.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libs/installer/downloadfiletask.cpp b/src/libs/installer/downloadfiletask.cpp
index 2c99e04e1..a5d47ad3b 100644
--- a/src/libs/installer/downloadfiletask.cpp
+++ b/src/libs/installer/downloadfiletask.cpp
@@ -225,13 +225,13 @@ void Downloader::onFinished(QNetworkReply *reply)
}
const QByteArray expectedCheckSum = data.taskItem.value(TaskRole::Checksum).toByteArray();
+ bool checksumMismatch = false;
if (!expectedCheckSum.isEmpty()) {
- if (expectedCheckSum != data.observer->checkSum().toHex()) {
- m_futureInterface->reportException(TaskException(tr("Checksum mismatch detected for \"%1\".")
- .arg(reply->url().toString())));
- }
+ if (expectedCheckSum != data.observer->checkSum().toHex())
+ checksumMismatch = true;
}
- m_futureInterface->reportResult(FileTaskResult(filename, data.observer->checkSum(), data.taskItem));
+ m_futureInterface->reportResult(FileTaskResult(filename, data.observer->checkSum(), data.taskItem,
+ checksumMismatch));
m_downloads.erase(reply);
m_redirects.remove(reply);