diff --git a/mqtt/qmqtt_socket.cpp b/mqtt/qmqtt_socket.cpp index f0628f0..5805f94 100644 --- a/mqtt/qmqtt_socket.cpp +++ b/mqtt/qmqtt_socket.cpp @@ -41,9 +41,9 @@ QMQTT::Socket::Socket(QObject* parent) connect(_socket.data(), &QTcpSocket::connected, this, &SocketInterface::connected); connect(_socket.data(), &QTcpSocket::disconnected, this, &SocketInterface::disconnected); connect(_socket.data(), - static_cast(&QTcpSocket::error), + SIGNAL(error(QTcpSocket::error)), this, - static_cast(&SocketInterface::error)); + SLOT(errorHandler(SocketInterface::error))); } QMQTT::Socket::~Socket() diff --git a/mqtt/qmqtt_ssl_socket.cpp b/mqtt/qmqtt_ssl_socket.cpp index 2d3a808..9f70434 100644 --- a/mqtt/qmqtt_ssl_socket.cpp +++ b/mqtt/qmqtt_ssl_socket.cpp @@ -46,9 +46,9 @@ QMQTT::SslSocket::SslSocket(const QSslConfiguration& config, QObject* parent) connect(_socket.data(), &QSslSocket::encrypted, this, &SocketInterface::connected); connect(_socket.data(), &QSslSocket::disconnected, this, &SocketInterface::disconnected); connect(_socket.data(), - static_cast(&QSslSocket::error), + SIGNAL(error(QSslSocket::error)), this, - static_cast(&SocketInterface::error)); + SLOT(errorHandler(SocketInterface::error))); connect(_socket.data(), static_cast&)>(&QSslSocket::sslErrors), this,