authorgravatar for 35903594+patrickwick@users.noreply.github.comPatrick Wickenhaeuser <35903594+patrickwick@users.noreply.github.com> 2024-10-04 12:38:35+02:00
committergravatar for 35903594+patrickwick@users.noreply.github.comPatrick Wickenhaeuser <35903594+patrickwick@users.noreply.github.com> 2024-10-04 15:49:50+02:00
log182c12de6989a7dd9419917a6cd0e6e804bc9d00
tree600becc4902c9d68ecb9fec544b32409d98862d9
parente1d54b6d1adb4b8e851bd949ade8cdc5fb840a9b

19009: zig objcopy: fix typo in abort messages


1 files changed, 3 insertions(+), 3 deletions(-)

lib/compiler/objcopy.zig+3-3
...@@ -865,7 +865,7 @@ fn ElfFile(comptime is_64: bool) type {...@@ -865,7 +865,7 @@ fn ElfFile(comptime is_64: bool) type {
865 // program header: list of segments865 // program header: list of segments
866 const program_segments = blk: {866 const program_segments = blk: {
867 if (@sizeOf(Elf_Phdr) != header.phentsize)867 if (@sizeOf(Elf_Phdr) != header.phentsize)
868 fatal("zig objcopy: unsuported ELF file, unexpected phentsize ({d})", .{header.phentsize});868 fatal("zig objcopy: unsupported ELF file, unexpected phentsize ({d})", .{header.phentsize});
869869
870 const program_header = try allocator.alloc(Elf_Phdr, header.phnum);870 const program_header = try allocator.alloc(Elf_Phdr, header.phnum);
871 const bytes_read = try in_file.preadAll(std.mem.sliceAsBytes(program_header), header.phoff);871 const bytes_read = try in_file.preadAll(std.mem.sliceAsBytes(program_header), header.phoff);
...@@ -877,7 +877,7 @@ fn ElfFile(comptime is_64: bool) type {...@@ -877,7 +877,7 @@ fn ElfFile(comptime is_64: bool) type {
877 // section header877 // section header
878 const sections = blk: {878 const sections = blk: {
879 if (@sizeOf(Elf_Shdr) != header.shentsize)879 if (@sizeOf(Elf_Shdr) != header.shentsize)
880 fatal("zig objcopy: unsuported ELF file, unexpected shentsize ({d})", .{header.shentsize});880 fatal("zig objcopy: unsupported ELF file, unexpected shentsize ({d})", .{header.shentsize});
881881
882 const section_header = try allocator.alloc(Section, header.shnum);882 const section_header = try allocator.alloc(Section, header.shnum);
883883
...@@ -1126,7 +1126,7 @@ fn ElfFile(comptime is_64: bool) type {...@@ -1126,7 +1126,7 @@ fn ElfFile(comptime is_64: bool) type {
1126 if (section.section.sh_type == elf.SHT_NOBITS)1126 if (section.section.sh_type == elf.SHT_NOBITS)
1127 continue;1127 continue;
1128 if (section.section.sh_offset < offset) {1128 if (section.section.sh_offset < offset) {
1129 fatal("zig objcopy: unsuported ELF file", .{});1129 fatal("zig objcopy: unsupported ELF file", .{});
1130 }1130 }
1131 offset = section.section.sh_offset;1131 offset = section.section.sh_offset;
1132 }1132 }