From 4f11a405a5de958875907120e4060e88da7aabcb Mon Sep 17 00:00:00 2001 From: Ryan Oldenburg Date: Mon, 15 Jan 2024 13:43:57 -0600 Subject: [PATCH] msg_nosignal --- src/ready/connections.nim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ready/connections.nim b/src/ready/connections.nim index fec0334..1ffdfc4 100644 --- a/src/ready/connections.nim +++ b/src/ready/connections.nim @@ -82,7 +82,7 @@ proc send*( for arg in args: msg.add "$" & $arg.len & "\r\n" & arg & "\r\n" - if conn.socket.send(msg[0].addr, msg.len.cint, 0) < 0: + if conn.socket.send(msg[0].addr, msg.len.cint, MSG_NOSIGNAL) < 0: raise newException(RedisError, osErrorMsg(osLastError())) proc send*( @@ -103,7 +103,7 @@ proc send*( for arg in args: msg.add "$" & $arg.len & "\r\n" & arg & "\r\n" - if conn.socket.send(msg[0].addr, msg.len.cint, 0) < 0: + if conn.socket.send(msg[0].addr, msg.len.cint, MSG_NOSIGNAL) < 0: raise newException(RedisError, osErrorMsg(osLastError())) proc recvBytes(conn: RedisConn) {.raises: [RedisError].} =