diff options
Diffstat (limited to 'util/cbfstool')
-rw-r--r-- | util/cbfstool/common.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/util/cbfstool/common.c b/util/cbfstool/common.c index 97bf168402..137aeb7bb8 100644 --- a/util/cbfstool/common.c +++ b/util/cbfstool/common.c @@ -273,11 +273,13 @@ uint64_t intfiletype(const char *name) void print_cbfs_directory(const char *filename) { + char *name = strdup(filename); printf ("%s: %d kB, bootblocksize %d, romsize %d, offset 0x%x\n" "alignment: %d bytes, architecture: %s\n\n", - basename((char *)filename), romsize / 1024, ntohl(master_header->bootblocksize), + basename(name), romsize / 1024, ntohl(master_header->bootblocksize), romsize, ntohl(master_header->offset), align, arch_to_string(arch)); + free(name); printf("%-30s %-10s %-12s Size\n", "Name", "Offset", "Type"); uint32_t current = phys_start; while (current < phys_end) { |