diff --git a/src/io/network/tcpSocket.cpp b/src/io/network/tcpSocket.cpp index 402100b..657d323 100644 --- a/src/io/network/tcpSocket.cpp +++ b/src/io/network/tcpSocket.cpp @@ -25,7 +25,11 @@ static inline int recv(SOCKET s, void* buf, size_t len, int flags) #include #include #include +#if defined(__APPLE__) +static constexpr int flags = 0; +#else static constexpr int flags = MSG_NOSIGNAL; +#endif static constexpr intptr_t INVALID_SOCKET = -1; #endif diff --git a/src/io/network/udpSocket.cpp b/src/io/network/udpSocket.cpp index 0b585e6..91f2e61 100644 --- a/src/io/network/udpSocket.cpp +++ b/src/io/network/udpSocket.cpp @@ -23,7 +23,11 @@ static inline int sendto(SOCKET s, const void* msg, size_t len, int flags, const #include #include #include +#if defined(__APPLE__) +static constexpr int flags = 0; +#else static constexpr int flags = MSG_NOSIGNAL; +#endif static constexpr intptr_t INVALID_SOCKET = -1; // Define IPV6_ADD_MEMBERSHIP for FreeBSD and Mac OS X #ifndef IPV6_ADD_MEMBERSHIP