mirror of
https://github.com/overte-org/overte.git
synced 2025-08-03 23:43:30 +02:00
actually change the system socket buffer size
This commit is contained in:
parent
e7f5bec3d0
commit
3f0eecc599
1 changed files with 2 additions and 1 deletions
|
@ -39,7 +39,7 @@ void Socket::rebind() {
|
|||
quint16 oldPort = _udpSocket.localPort();
|
||||
|
||||
_udpSocket.close();
|
||||
_udpSocket.bind(QHostAddress::AnyIPv4, oldPort);
|
||||
bind(QHostAddress::AnyIPv4, oldPort);
|
||||
}
|
||||
|
||||
void Socket::setSystemBufferSizes() {
|
||||
|
@ -63,6 +63,7 @@ void Socket::setSystemBufferSizes() {
|
|||
int oldBufferSize = _udpSocket.socketOption(bufferOpt).toInt();
|
||||
|
||||
if (oldBufferSize < numBytes) {
|
||||
_udpSocket.setSocketOption(bufferOpt, QVariant(numBytes));
|
||||
int newBufferSize = _udpSocket.socketOption(bufferOpt).toInt();
|
||||
|
||||
qCDebug(networking) << "Changed socket" << bufferTypeString << "buffer size from" << oldBufferSize << "to"
|
||||
|
|
Loading…
Reference in a new issue