net/SocketDescriptor: WriteNoWait() uses MSG_NOSIGNAL
This commit is contained in:

committed by
Max Kellermann

parent
3813433e02
commit
9c421997bf
@@ -484,6 +484,9 @@ SocketDescriptor::WriteNoWait(std::span<const std::byte> src) const noexcept
|
|||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
flags |= MSG_DONTWAIT;
|
flags |= MSG_DONTWAIT;
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef __linux__
|
||||||
|
flags |= MSG_NOSIGNAL;
|
||||||
|
#endif
|
||||||
|
|
||||||
return Send(src, flags);
|
return Send(src, flags);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user