websocket forked from zzstoatzz.io/websocket.zig

server: fix segfault in runIo with allocator-taking clientMessage

runIo reuses Blocking(H)'s read loop, which passed fba=undefined on the assumption that comptime blockingMode() compiles the fba branch out. that holds for true blocking mode, but runIo runs with blockingMode() false on linux/macos, so an allocator-taking clientMessage handler walked into the FallbackAllocator and dereferenced undefined memory. make the per-thread fba optional: the worker path passes it as before, blocking-style read loops pass null and the message allocator falls back to the arena. regression test drives runIo with TestHandler's allocator variant (panics without the fix). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>


Author
Co-author Claude Fable 5 Date Commit Parent 2310b046
+55 -9
1 changed file
+55 -9
1 changed file