mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 08:04:01 +02:00
ifdef to handle getsockopt format requirements on windows
This commit is contained in:
parent
c4b8ff8952
commit
e03e82a29b
1 changed files with 6 additions and 0 deletions
|
@ -89,7 +89,13 @@ NodeList::NodeList(char newOwnerType, unsigned short int newSocketListenPort) :
|
|||
void NodeList::changeSendSocketBufferSize(int numSendBytes) {
|
||||
// change the socket send buffer size to be 1MB
|
||||
int oldBufferSize = 0;
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
int sizeOfInt = sizeof(oldBufferSize);
|
||||
#else
|
||||
unsigned int sizeOfInt = sizeof(oldBufferSize);
|
||||
#endif
|
||||
|
||||
getsockopt(_nodeSocket.socketDescriptor(), SOL_SOCKET, SO_SNDBUF, reinterpret_cast<char*>(&oldBufferSize), &sizeOfInt);
|
||||
|
||||
const int LARGER_SNDBUF_SIZE = 1048576;
|
||||
|
|
Loading…
Reference in a new issue