Prevent absolutely ridiculous and silly linux behaviour to kill programs

* By default on linux some send() errors will kill the process instead of
  returning an error code.
This commit is contained in:
baldurk committed 2026-10-23 23:13:16 +01:00
1 parent 64b3775332
commit f1c7eff75b
1 file changed
+5 -1
+5 -1
View File
@@ -167,7 +167,11 @@ bool Socket::SendDataBlocking(const void *buf, uint32_t length)
while(sent < length)
{
ssize_t ret = send((int)socket, src, length - sent, 0);
int flags = 0;
#if ENABLED(RDOC_LINUX)
flags = MSG_NOSIGNAL;
#endif
ssize_t ret = send((int)socket, src, length - sent, flags);
if(ret <= 0)
{