QTcpServer listens on a different port than specified
-
Hello, I am writing a simple client server application using QTcpServer and doing the following
Server::Server() { quint16 port = quint16(2323); if (listen(QHostAddress::Any), port) { qDebug() << "start" << this->isListening() << this->serverAddress() << this->serverPort(); } else { qDebug() << "error"; } }But it doesn't listen to the specified port and
this->serverPort();displays a different port each time. Port 2323 is not busy