diff --git a/src/linuxArm32HfpMain/kotlin/Posix.kt b/src/linuxArm32HfpMain/kotlin/Posix.kt index 3700742..fa5b024 100644 --- a/src/linuxArm32HfpMain/kotlin/Posix.kt +++ b/src/linuxArm32HfpMain/kotlin/Posix.kt @@ -2,7 +2,7 @@ import kotlinx.cinterop.* import platform.posix.* actual fun send(socket: Int, buf: CValuesRef?, len: Int, flags: Int): Int { - return platform.posix.send(socket.convert(), buf, len.convert(), flags) + return platform.posix.send(socket.convert(), buf, len.convert(), flags or MSG_NOSIGNAL) } actual fun recv(socket: Int, buf: CValuesRef?, len: Int, flags: Int): Int { diff --git a/src/linuxX64Main/kotlin/Posix.kt b/src/linuxX64Main/kotlin/Posix.kt index f04f655..9f69ae3 100644 --- a/src/linuxX64Main/kotlin/Posix.kt +++ b/src/linuxX64Main/kotlin/Posix.kt @@ -2,7 +2,7 @@ import kotlinx.cinterop.* import platform.posix.* actual fun send(socket: Int, buf: CValuesRef?, len: Int, flags: Int): Int { - return platform.posix.send(socket.convert(), buf, len.convert(), flags).convert() + return platform.posix.send(socket.convert(), buf, len.convert(), flags or MSG_NOSIGNAL).convert() } actual fun recv(socket: Int, buf: CValuesRef?, len: Int, flags: Int): Int {