From 6d6bfcb9ad2ed2f8613ac3120233b9dbe011c644 Mon Sep 17 00:00:00 2001 From: Timur Pocheptsov Date: Wed, 25 Mar 2020 08:37:16 +0100 Subject: QtNetwork remove deprecated signals MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use 'errorOccurred' instead of 'error' and 'sslHandshakeErrors' instead of 'sslErrors'. Fixes: QTBUG-82605 Change-Id: I19d4845b16c7b636af7b0658d4fbbba4eef9d029 Reviewed-by: Edward Welbourne Reviewed-by: MÃ¥rten Nordheim --- tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp') diff --git a/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp b/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp index 79bd4994db..0ac87a9cb1 100644 --- a/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp +++ b/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp @@ -4450,9 +4450,6 @@ void tst_QSslSocket::oldErrorsOnSocketReuse() #if QT_CONFIG(openssl) -void (QSslSocket::*const tlsErrorSignal)(const QList &) = &QSslSocket::sslErrors; -void (QAbstractSocket::*const socketErrorSignal)(QAbstractSocket::SocketError) = &QAbstractSocket::error; - void tst_QSslSocket::alertMissingCertificate() { // In this test we want a server to abort the connection due to the failing @@ -4474,7 +4471,7 @@ void tst_QSslSocket::alertMissingCertificate() server.config.setMissingCertificateIsFatal(true); QSslSocket clientSocket; - connect(&clientSocket, tlsErrorSignal, [&clientSocket](const QList &errors){ + connect(&clientSocket, &QSslSocket::sslErrors, [&clientSocket](const QList &errors){ qDebug() << "ERR"; clientSocket.ignoreSslErrors(errors); }); @@ -4497,7 +4494,7 @@ void tst_QSslSocket::alertMissingCertificate() // Presumably, RemoteHostClosedError for the client and SslHandshakeError // for the server: - connect(&clientSocket, socketErrorSignal, earlyQuitter); + connect(&clientSocket, &QAbstractSocket::errorOccurred, earlyQuitter); connect(&server, &SslServer::socketError, earlyQuitter); runner.enterLoopMSecs(1000); @@ -4547,7 +4544,7 @@ void tst_QSslSocket::alertInvalidCertificate() // Presumably, RemoteHostClosedError for the server and SslHandshakeError // for the client: - connect(&clientSocket, socketErrorSignal, earlyQuitter); + connect(&clientSocket, &QAbstractSocket::errorOccurred, earlyQuitter); connect(&server, &SslServer::socketError, earlyQuitter); runner.enterLoopMSecs(1000); -- cgit v1.2.3