ioctl doesn't implement FIONREAD for wasi:socket handles
Opened this issue · 2 comments
pavelsavara commented
wasi-libc/libc-bottom-half/cloudlibc/src/libc/sys/ioctl/ioctl.c
Lines 22 to 37 in 7d4d3b8
badeend commented
I think wasi-libc can implement it like:
return if state == TCP_SOCKET_STATE_CONNECTED && input_pollable.ready() { 8192 } else { 0 };
Some additional info: WebAssembly/wasi-sockets#17