summaryrefslogtreecommitdiff
path: root/builtin/ls-tree.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2018-11-19 16:24:41 +0900
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-11-19 16:24:41 +0900
commitf5f0f68d61301c3ffb2f8da84f627547e8f9a94c (patch)
tree2c4e826363e1febaaf1c7fd6187e8fa714561c5d /builtin/ls-tree.c
parentMerge branch 'tb/xcurl-off-t' (diff)
parentUpcast size_t variables to uintmax_t when printing (diff)
downloadtgif-f5f0f68d61301c3ffb2f8da84f627547e8f9a94c.tar.xz
Merge branch 'tb/print-size-t-with-uintmax-format'
Code preparation to replace ulong vars with size_t vars where appropriate. * tb/print-size-t-with-uintmax-format: Upcast size_t variables to uintmax_t when printing
Diffstat (limited to 'builtin/ls-tree.c')
-rw-r--r--builtin/ls-tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/ls-tree.c b/builtin/ls-tree.c
index fe3b952cb3..7d581d6463 100644
--- a/builtin/ls-tree.c
+++ b/builtin/ls-tree.c
@@ -100,7 +100,7 @@ static int show_tree(const struct object_id *oid, struct strbuf *base,
"BAD");
else
xsnprintf(size_text, sizeof(size_text),
- "%lu", size);
+ "%"PRIuMAX, (uintmax_t)size);
} else
xsnprintf(size_text, sizeof(size_text), "-");
printf("%06o %s %s %7s\t", mode, type,