forked from pool/zanshin
c63f948959
OBS-URL: https://build.opensuse.org/request/show/561699 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/zanshin?expand=0&rev=3
32 lines
999 B
Diff
32 lines
999 B
Diff
From 55c7126edf9e956c14ed5c82973399c7db48d965 Mon Sep 17 00:00:00 2001
|
|
From: Wolfgang Bauer <wbauer@tmo.at>
|
|
Date: Thu, 4 Jan 2018 11:59:21 +0100
|
|
Subject: [PATCH] Fix build with Qt 5.6
|
|
|
|
qAsConst() only exists in Qt 5.7.0 and higher.
|
|
This basically reverts commit ff4cbbff when compiling with Qt < 5.7.0,
|
|
to make it build on Leap 42.x.
|
|
---
|
|
src/utils/dependencymanager.cpp | 4 ++++
|
|
1 file changed, 4 insertions(+)
|
|
|
|
diff --git a/src/utils/dependencymanager.cpp b/src/utils/dependencymanager.cpp
|
|
index 560a768e..2f70fad1 100644
|
|
--- a/src/utils/dependencymanager.cpp
|
|
+++ b/src/utils/dependencymanager.cpp
|
|
@@ -44,7 +44,11 @@ DependencyManager::DependencyManager(const DependencyManager &other)
|
|
|
|
DependencyManager::~DependencyManager()
|
|
{
|
|
+#if QT_VERSION < QT_VERSION_CHECK(5,7,0)
|
|
+ foreach (void (*cleanupFunction)(DependencyManager*), m_cleanupFunctions) {
|
|
+#else
|
|
for (const auto &cleanupFunction : qAsConst(m_cleanupFunctions)) {
|
|
+#endif
|
|
cleanupFunction(this);
|
|
}
|
|
}
|
|
--
|
|
2.13.6
|
|
|