| ... | @@ -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 segments | 865 | // 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}); |
| 869 | | 869 | |
| 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 header | 877 | // 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}); |
| 881 | | 881 | |
| 882 | const section_header = try allocator.alloc(Section, header.shnum); | 882 | const section_header = try allocator.alloc(Section, header.shnum); |
| 883 | | 883 | |
| ... | @@ -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 | } |