From 075e73331991f38eebad4e240d1c4ac732d5e780 Mon Sep 17 00:00:00 2001 From: Sadhbh Code Date: Thu, 4 Jun 2026 21:59:26 +0100 Subject: [PATCH] Wasix-LibC supports SOL_SOCKET + SO_KEEPALIVE, however does not support additional options such as TCP_KEEPIDLE, TCP_KEEPINTVL, or TCP_KEEPCNT - so we disable them --- src/unix/tcp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/unix/tcp.c b/src/unix/tcp.c index 852c189c7a7..88f1f1df87a 100644 --- a/src/unix/tcp.c +++ b/src/unix/tcp.c @@ -489,6 +489,10 @@ int uv__tcp_keepalive(int fd, int on, unsigned int delay) { if (delay < 1) return UV_EINVAL; +#if defined(__wasi__) || defined(__wasm32__) + return 0; +#endif + #ifdef __sun /* The implementation of TCP keep-alive on Solaris/SmartOS is a bit unusual * compared to other Unix-like systems.