Fix -Wunused-but-set-variable in QTcpSocket documentation snippet

Pick-to: 6.2 6.3 5.15
Task-number: QTBUG-101883
Change-Id: I54dc7229565cef199f306a0ac837a932aeb00ec6
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
Tor Arne Vestbø 2022-03-18 13:32:22 +01:00
parent bdb9a254c2
commit e14466aa66

View File

@ -50,7 +50,7 @@
#include <QTcpSocket>
void test_tcpwait()
int test_tcpwait()
{
QTcpSocket socket;
socket.connectToHost("localhost", 1025);
@ -69,4 +69,5 @@ void test_tcpwait()
break;
}
//! [0]
return numReadTotal;
}