WebAssembly / wasi-libc

WASI libc implementation for WebAssembly
https://wasi.dev
Other
862 stars 203 forks source link

getsockopt, setsockopt doesn't implement SO_RCVTIMEO,SO_SNDTIMEO for wasi:socket handles #539

Open pavelsavara opened 2 months ago

pavelsavara commented 2 months ago

https://github.com/WebAssembly/wasi-libc/blob/7d4d3b83fc66c79b3faa5989e67ed2d1042dacaf/libc-bottom-half/sources/sockopt.c#L464-L470

abrown commented 2 months ago

cc: @badeend, @dicej

badeend commented 2 months ago

My suggestion is to keep track of the configured timeout values in wasi-libc and update the sendto & recvfrom implementations to take them into account where they're currently calling poll_method_pollable_block