std: fix writeSplatHeaderLimit bug affecting chunked HTTP
The writeSplatHeaderLimitFinish logic correctly takes the limited prefix slice of the header, but fails to chop off excess in the data vector slices, causing a drain longer than the limit.
I spotted this by accident, and found one usage in std, in the HTTP chunked encoding writer, and the issue #24944 that I speculate this commit will fix. I was able to partly reproduce it on Linux but only by disabling sendfile and some other weird kludges.
First time hacking the Zig std. I verified tests failing and then passing with
zig test lib/std/std.zig --zig-lib-dir lib
This looks like a nice bug fix, but, unfortunately, this does not fix #24944 (see https://github.com/ziglang/zig/issues/24944#issuecomment-3368869038)
The fix was included as part of https://github.com/ziglang/zig/pull/25981
Would you mind rebasing and just including the new test cases?