AndroidSdkDownloader: Add a handler for unarchiver error

Call logError() in this case.

Change-Id: Iab2b44ebc00fd7fe3ae755e7e575f8eb0f314c9f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Jarek Kobus
2023-06-09 10:29:26 +02:00
parent a250ddb668
commit 64078126a9

View File

@@ -178,11 +178,14 @@ void AndroidSdkDownloader::downloadAndExtractSdk()
(*storage)->parentDir().pathAppended(Constants::cmdlineToolsName));
QMetaObject::invokeMethod(this, [this] { emit sdkExtracted(); }, Qt::QueuedConnection);
};
const auto onUnarchiverError = [this](const Unarchiver &) {
logError(Tr::tr("Unarchiving error."));
};
const Group root {
Storage(storage),
NetworkQueryTask(onQuerySetup, onQueryDone, onQueryError),
UnarchiverTask(onUnarchiveSetup, onUnarchiverDone)
UnarchiverTask(onUnarchiveSetup, onUnarchiverDone, onUnarchiverError)
};
m_taskTree.reset(new TaskTree(root));