zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit f4706c23e9aadb53dd6620107ae5c7676e2dab86 (tree)
parent 372acb83500e9f910f48b78eaca4bf35a6e4f9d8
Author: Jakub Konka <kubkon@jakubkonka.com>
Date:   Sun, 18 Sep 2022 11:01:29 +0200

macho: fix after sync with master

Diffstat:
Msrc/link/MachO/Object.zig | 8++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/link/MachO/Object.zig b/src/link/MachO/Object.zig @@ -249,7 +249,7 @@ pub fn splitIntoAtoms(self: *Object, macho_file: *MachO, object_id: u32) !void { const in_symtab = self.in_symtab orelse { for (self.sections.items) |sect, id| { if (sect.isDebug()) continue; - const match = (try macho_file.getOutputSection(sect)) orelse { + const out_sect_id = (try macho_file.getOutputSection(sect)) orelse { log.debug(" unhandled section", .{}); continue; }; @@ -261,7 +261,7 @@ pub fn splitIntoAtoms(self: *Object, macho_file: *MachO, object_id: u32) !void { try self.symtab.append(gpa, .{ .n_strx = 0, .n_type = macho.N_SECT, - .n_sect = match + 1, + .n_sect = out_sect_id + 1, .n_desc = 0, .n_value = sect.addr, }); @@ -282,10 +282,10 @@ pub fn splitIntoAtoms(self: *Object, macho_file: *MachO, object_id: u32) !void { code, relocs, &.{}, - match, + out_sect_id, sect, ); - try macho_file.addAtomToSection(atom, match); + try macho_file.addAtomToSection(atom); } return; };