| author | |
| committer | |
| log | 092299036705eb597f6c9c3c1cb9939d5fb9d131 |
| tree | a650df7370ea593210c25eed4a2f81f1799b0811 |
| parent | cd7d8dff26280146a720d907755a41406de4d510 |
| signature |
Little-endian is what `std.zig.Server` expects, but the old logic just
send the raw bytes of the struct, so sent in native endian (causing a
crash on big-endian targets).1 files changed, 4 insertions(+), 1 deletions(-)
lib/std/Build/Step.zig+4-1| ... | ... | @@ -680,7 +680,10 @@ fn sendMessage(file: std.fs.File, tag: std.zig.Client.Message.Tag) !void { |
| 680 | 680 | .tag = tag, |
| 681 | 681 | .bytes_len = 0, |
| 682 | 682 | }; |
| 683 | try file.writeAll(std.mem.asBytes(&header)); | |
| 683 | var w = file.writer(&.{}); | |
| 684 | w.interface.writeStruct(header, .little) catch |err| switch (err) { | |
| 685 | error.WriteFailed => return w.err.?, | |
| 686 | }; | |
| 684 | 687 | } |
| 685 | 688 | |
| 686 | 689 | pub fn handleVerbose( |