mirror of
https://github.com/ziglang/zig.git
synced 2026-02-13 04:48:20 +00:00
correct padding handling between std.pdb.ModInfo entries in DbiStream
This commit is contained in:
parent
6abe6dbfe4
commit
0d4a5c40bc
@ -881,8 +881,9 @@ fn openSelfDebugInfoWindows(allocator: *mem.Allocator) !DebugInfo {
|
||||
const obj_file_name = try dbi.readNullTermString(allocator);
|
||||
this_record_len += obj_file_name.len + 1;
|
||||
|
||||
const march_forward_bytes = this_record_len % 4;
|
||||
if (march_forward_bytes != 0) {
|
||||
if (this_record_len % 4 != 0) {
|
||||
const round_to_next_4 = (this_record_len | 0x3) + 1;
|
||||
const march_forward_bytes = round_to_next_4 - this_record_len;
|
||||
try dbi.seekForward(march_forward_bytes);
|
||||
this_record_len += march_forward_bytes;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user