Changes for MacOS. Can be compiled, but there are still some issues.
This commit is contained in:
@@ -82,10 +82,15 @@ ClientStateInit::Process(ClientThread &client)
|
||||
if (IOCTLSOCKET(context.GetSocket(), FIONBIO, &mode) == SOCKET_ERROR)
|
||||
throw ClientException(__FILE__, __LINE__, ERR_SOCK_CREATION_FAILED, SOCKET_ERRNO());
|
||||
|
||||
// The following call is optional - the return value is not checked.
|
||||
// The following calls are optional - the return value is not checked.
|
||||
int nodelay = 1;
|
||||
setsockopt(context.GetSocket(), SOL_SOCKET, TCP_NODELAY, (char *)&nodelay, sizeof(nodelay));
|
||||
|
||||
#ifdef SO_NOSIGPIPE
|
||||
int nosigpipe = 1;
|
||||
setsockopt(context.GetSocket(), SOL_SOCKET, SO_NOSIGPIPE, (char *)&nosigpipe, sizeof(nosigpipe));
|
||||
#endif
|
||||
|
||||
client.SetState(ClientStateStartResolve::Instance());
|
||||
|
||||
return MSG_SOCK_INIT_DONE;
|
||||
|
||||
Reference in New Issue
Block a user