Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.0.1
-
None
-
Linux (Gentoo x64)
Description
Qt 5 and QTBUG-121 introduced a new API to bind the local address for QTcpSocket. However, it does not work actually, the socket always use default local address to connect.
The cause is QAbstractSocketPrivate::_q_connectToNextAddress() calls initSocketLayer(), which close the bound socket, replace it with a newly created socket, and leave the new socket unbound.