mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-09-02 15:02:51 +08:00
The scan stepped over the NUL that ends the received data before breaking, so on a request whose headers were cut short it returned a pointer one past the data. handle_post() then tested that byte for the end of the header, reading whatever an earlier packet had left there instead of the NUL the appcall wrote, and could go on to run an endpoint against the stale bytes. Break before advancing so the returned pointer sits on the NUL and the caller's check sees it.