File: src/server/server.zig:2231-2237; caller run() at 604-608
Severity: MEDIUM
Status: ✅ FIXED
handleClient now maps error.WouldBlock to a benign no-op return; only real
read failures propagate as error.ReadFailed and tear the client down.
Test: handleClient tolerates EAGAIN on non-blocking fd — bug #373
(non-blocking pipe with a registered MessageReader; handleClient must return
without error).
const n = std.posix.read(fd, &buf) catch |err| {
...
return error.ReadFailed; // → removeClient(cfd)
registerDisplayClient flips the socket to non-blocking; on any spurious wake
or edge race the read returns WouldBlock and the whole DisplayClient is
destroyed instead of waiting for the next POLLIN.
Map error.WouldBlock to a benign zero-progress return in handleClient;
propagate only real errors as disconnects.