StudioWelcome: Fix QTC_ASSERT

Deleting QtcProcess instance directly from
one of its signal handlers will lead to crash.

Change-Id: Ida231f29dc6a717dfe4971da9743b1fb9b225495
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
Thomas Hartmann
2022-08-23 16:11:20 +02:00
committed by Tim Jenssen
parent daabcbbf73
commit 83ce87a625

View File

@@ -503,7 +503,7 @@ bool DataModelDownloader::start()
QTC_ASSERT(archive->isValid(), delete archive; return ); QTC_ASSERT(archive->isValid(), delete archive; return );
QObject::connect(archive, &Utils::Archive::finished, this, [this, archive](bool ret) { QObject::connect(archive, &Utils::Archive::finished, this, [this, archive](bool ret) {
QTC_CHECK(ret); QTC_CHECK(ret);
delete archive; archive->deleteLater();
emit finished(); emit finished();
}); });
archive->unarchive(); archive->unarchive();