diff options
Diffstat (limited to 'src/link/MachO/Dylib.zig')
| -rw-r--r-- | src/link/MachO/Dylib.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/link/MachO/Dylib.zig b/src/link/MachO/Dylib.zig index e3998a8548..5b4ab6aa18 100644 --- a/src/link/MachO/Dylib.zig +++ b/src/link/MachO/Dylib.zig @@ -180,7 +180,7 @@ pub fn parse(self: *Dylib, allocator: *Allocator, target: std.Target) !void { fn readLoadCommands(self: *Dylib, allocator: *Allocator, reader: anytype) !void { const should_lookup_reexports = self.header.?.flags & macho.MH_NO_REEXPORTED_DYLIBS == 0; - try self.load_commands.ensureTotalCapacity(allocator, self.header.?.ncmds); + try self.load_commands.ensureUnusedCapacity(allocator, self.header.?.ncmds); var i: u16 = 0; while (i < self.header.?.ncmds) : (i += 1) { |
