diff options
Diffstat (limited to 'src/target/image.c')
-rw-r--r-- | src/target/image.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/target/image.c b/src/target/image.c index 624f319..a457b56 100644 --- a/src/target/image.c +++ b/src/target/image.c @@ -411,7 +411,7 @@ int image_elf_read_headers(image_t *image) { if ((field32(elf, elf->segments[i].p_type) == PT_LOAD) && (field32(elf, elf->segments[i].p_filesz) != 0)) { - image->sections[j].size = field32(elf, elf->segments[i].p_memsz); + image->sections[j].size = field32(elf, elf->segments[i].p_filesz); image->sections[j].base_address = field32(elf, elf->segments[i].p_paddr); image->sections[j].private = &elf->segments[i]; image->sections[j].flags = field32(elf, elf->segments[i].p_flags); @@ -1027,3 +1027,4 @@ int image_calculate_checksum(u8* buffer, u32 nbytes, u32* checksum) } + |