mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-01-27 16:57:00 -06:00
Add a couple of headers that Qt 5.8 seems to be more picky about, and fix the free port check to use TCP not UDP
This commit is contained in:
parent
c391696054
commit
ea6d97c49d
@ -16,6 +16,8 @@
|
||||
|
||||
#if QT_VERSION >= 0x050000
|
||||
#include <QtWidgets>
|
||||
#include <QNetworkRequest>
|
||||
#include <QNetworkReply>
|
||||
#else
|
||||
#include <QApplication>
|
||||
#include <QDebug>
|
||||
@ -66,8 +68,8 @@ int main(int argc, char * argv[])
|
||||
// Hence - putting this code in a code block so the scope of the socket
|
||||
// variable vanishes to make that socket available.
|
||||
{
|
||||
QUdpSocket socket;
|
||||
socket.bind(0, QUdpSocket::ShareAddress);
|
||||
QTcpSocket socket;
|
||||
socket.bind(0, QTcpSocket::ShareAddress);
|
||||
port = socket.localPort();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user