mirror of
https://github.com/glest/glest-source.git
synced 2025-08-16 05:13:59 +02:00
- stupid win32 compile fix for sockets
This commit is contained in:
@@ -33,6 +33,8 @@
|
||||
#include <iphlpapi.h>
|
||||
#include <strstream>
|
||||
|
||||
#define MSG_NOSIGNAL 0
|
||||
|
||||
#else
|
||||
|
||||
#include <unistd.h>
|
||||
@@ -981,7 +983,8 @@ int Socket::send(const void *data, int dataSize) {
|
||||
MutexSafeWrapper safeMutex(&dataSynchAccessor);
|
||||
|
||||
//SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s Line: %d]\n",__FILE__,__FUNCTION__,__LINE__);
|
||||
bytesSent = ::send(sock, data, dataSize, MSG_NOSIGNAL);
|
||||
|
||||
bytesSent = ::send(sock, (const char *)data, dataSize, MSG_NOSIGNAL);
|
||||
//SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s Line: %d]\n",__FILE__,__FUNCTION__,__LINE__);
|
||||
}
|
||||
|
||||
@@ -1008,7 +1011,7 @@ int Socket::send(const void *data, int dataSize) {
|
||||
SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s Line: %d] attemptCount = %d, sock = %d, dataSize = %d, data = %p\n",__FILE__,__FUNCTION__,__LINE__,attemptCount,sock,dataSize,data);
|
||||
|
||||
MutexSafeWrapper safeMutex(&dataSynchAccessor);
|
||||
bytesSent = ::send(sock, data, dataSize, MSG_NOSIGNAL);
|
||||
bytesSent = ::send(sock, (const char *)data, dataSize, MSG_NOSIGNAL);
|
||||
|
||||
SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s] #2 EAGAIN during send, trying again returned: %d\n",__FILE__,__FUNCTION__,bytesSent);
|
||||
}
|
||||
|
Reference in New Issue
Block a user