mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -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
|
#if QT_VERSION >= 0x050000
|
||||||
#include <QtWidgets>
|
#include <QtWidgets>
|
||||||
|
#include <QNetworkRequest>
|
||||||
|
#include <QNetworkReply>
|
||||||
#else
|
#else
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QDebug>
|
#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
|
// Hence - putting this code in a code block so the scope of the socket
|
||||||
// variable vanishes to make that socket available.
|
// variable vanishes to make that socket available.
|
||||||
{
|
{
|
||||||
QUdpSocket socket;
|
QTcpSocket socket;
|
||||||
socket.bind(0, QUdpSocket::ShareAddress);
|
socket.bind(0, QTcpSocket::ShareAddress);
|
||||||
port = socket.localPort();
|
port = socket.localPort();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user