summaryrefslogtreecommitdiff
path: root/UDPExamples
diff options
context:
space:
mode:
Diffstat (limited to 'UDPExamples')
-rw-r--r--UDPExamples/MessageServer.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/UDPExamples/MessageServer.cpp b/UDPExamples/MessageServer.cpp
index ce7cd6fb..59907d52 100644
--- a/UDPExamples/MessageServer.cpp
+++ b/UDPExamples/MessageServer.cpp
@@ -39,11 +39,18 @@ public:
Radio::register_types ();
connect (this, &QIODevice::readyRead, this, &MessageServer::impl::pending_datagrams);
+#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect (this, static_cast<void (impl::*) (SocketError)> (&impl::error)
, [this] (SocketError /* e */)
{
Q_EMIT self_->error (errorString ());
});
+#else
+ connect (this, &impl::errorOccurred, [this] (SocketError /* e */)
+ {
+ Q_EMIT self_->error (errorString ());
+ });
+#endif
connect (clock_, &QTimer::timeout, this, &impl::tick);
clock_->start (NetworkMessage::pulse * 1000);
}