From 19baa7c503701459bfdef3aea9e657e3c89ccfe6 Mon Sep 17 00:00:00 2001 From: Luke Street Date: Sat, 27 Feb 2021 23:06:54 -0500 Subject: [PATCH] DownloadManager: Fix build with Qt <5.15 --- hecl-gui/DownloadManager.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hecl-gui/DownloadManager.cpp b/hecl-gui/DownloadManager.cpp index bc0445ec9..ade55a7eb 100644 --- a/hecl-gui/DownloadManager.cpp +++ b/hecl-gui/DownloadManager.cpp @@ -61,7 +61,8 @@ void DownloadManager::fetchIndex() { #if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0) connect(m_indexInProgress, &QNetworkReply::errorOccurred, this, &DownloadManager::indexError); #else - connect(m_indexInProgress, &QNetworkReply::error, this, &DownloadManager::indexError); + connect(m_indexInProgress, qOverload(&QNetworkReply::error), this, + &DownloadManager::indexError); #endif connect(m_indexInProgress, &QNetworkReply::encrypted, this, &DownloadManager::indexValidateCert); } @@ -81,7 +82,8 @@ void DownloadManager::fetchBinary(const QString& str, const QString& outPath) { #if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0) connect(m_binaryInProgress, &QNetworkReply::errorOccurred, this, &DownloadManager::binaryError); #else - connect(m_binaryInProgress, &QNetworkReply::error, this, &DownloadManager::binaryError); + connect(m_binaryInProgress, qOverload(&QNetworkReply::error), this, + &DownloadManager::binaryError); #endif connect(m_binaryInProgress, &QNetworkReply::encrypted, this, &DownloadManager::binaryValidateCert); connect(m_binaryInProgress, &QNetworkReply::downloadProgress, this, &DownloadManager::binaryDownloadProgress);