From f20ed9eef65cb9ce56f4a7abd07ad80979b888ad Mon Sep 17 00:00:00 2001 From: David Oberhollenzer Date: Thu, 10 Mar 2022 23:17:20 +0100 Subject: Fix: use correct printf specifier for 64bit types Signed-off-by: David Oberhollenzer --- extras/browse.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'extras') diff --git a/extras/browse.c b/extras/browse.c index fe5bfd8..2899ba5 100644 --- a/extras/browse.c +++ b/extras/browse.c @@ -14,6 +14,7 @@ #include "sqfs/block.h" #include "sqfs/dir.h" #include "sqfs/io.h" +#include "compat.h" #include #include @@ -353,7 +354,7 @@ static void stat_cmd(const char *filename) } break; case SQFS_INODE_EXT_FILE: - printf("Blocks start: %lu\n", + printf("Blocks start: " PRI_U64 "\n", inode->data.file_ext.blocks_start); printf("Block count: %lu\n", (unsigned long)sqfs_inode_get_file_block_count(inode)); @@ -361,8 +362,10 @@ static void stat_cmd(const char *filename) inode->data.file_ext.fragment_idx); printf("Fragment offset: %u\n", inode->data.file_ext.fragment_offset); - printf("File size: %lu\n", inode->data.file_ext.file_size); - printf("Sparse: %lu\n", inode->data.file_ext.sparse); + printf("File size: " PRI_U64 "\n", + inode->data.file_ext.file_size); + printf("Sparse: " PRI_U64 "\n", + inode->data.file_ext.sparse); printf("Hard link count: %u\n", inode->data.file_ext.nlink); printf("Xattr index: 0x%X\n", inode->data.file_ext.xattr_idx); -- cgit v1.2.3