diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2019-07-15 12:57:40 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2019-07-16 09:36:52 +0200 |
commit | 8a6d9c307851f3492ddc597f5f03e80f236a7857 (patch) | |
tree | 7711bc5ad2bd496d3f9bc3ace46474df38cc5f06 | |
parent | 0fc7e18bf7a24c9408602242d51a852905dfd0da (diff) | |
download | qtconnectivity-8a6d9c307851f3492ddc597f5f03e80f236a7857.tar.gz |
Fix compilation with C++20
Implicit capture of 'this' in [=] is deprecated in C++20.
Fix by using explicit capture.
Change-Id: I96132d83d87ae61986ba1b1ea3f9cf8e50059f1f
Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
-rw-r--r-- | src/bluetooth/qlowenergycontroller_bluezdbus.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bluetooth/qlowenergycontroller_bluezdbus.cpp b/src/bluetooth/qlowenergycontroller_bluezdbus.cpp index f019d9c2..26ceefb0 100644 --- a/src/bluetooth/qlowenergycontroller_bluezdbus.cpp +++ b/src/bluetooth/qlowenergycontroller_bluezdbus.cpp @@ -336,7 +336,7 @@ void QLowEnergyControllerPrivateBluezDBus::connectToDevice() QDBusPendingReply<> reply = device->Connect(); QDBusPendingCallWatcher* watcher = new QDBusPendingCallWatcher(reply, this); connect(watcher, &QDBusPendingCallWatcher::finished, this, - [=](QDBusPendingCallWatcher* call) { + [this](QDBusPendingCallWatcher* call) { QDBusPendingReply<> reply = *call; if (reply.isError()) { qCDebug(QT_BT_BLUEZ) << "BTLE_DBUS::connect() failed" @@ -358,7 +358,7 @@ void QLowEnergyControllerPrivateBluezDBus::disconnectFromDevice() QDBusPendingReply<> reply = device->Disconnect(); QDBusPendingCallWatcher* watcher = new QDBusPendingCallWatcher(reply, this); connect(watcher, &QDBusPendingCallWatcher::finished, this, - [=](QDBusPendingCallWatcher* call) { + [this](QDBusPendingCallWatcher* call) { QDBusPendingReply<> reply = *call; if (reply.isError()) { qCDebug(QT_BT_BLUEZ) << "BTLE_DBUS::disconnect() failed" |