If we use a port<1024 for HTTP server, then just assign a 'dynamic'/random port

This commit is contained in:
craig.p.drummond
2013-03-11 19:53:25 +00:00
committed by craig.p.drummond
parent d25382057c
commit 13afdc5600
4 changed files with 8 additions and 5 deletions

View File

@@ -186,7 +186,7 @@ HttpSocket::HttpSocket(const QString &addr, quint16 p)
}
}
}
listen(a.isNull() ? QHostAddress::LocalHost : a, p);
listen(a.isNull() ? QHostAddress::LocalHost : a, p<1024 ? 0 : p);
}
void HttpSocket::terminate()