diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2006-04-05 14:57:59 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2006-04-05 14:57:59 +0000 |
commit | 465874f3a31da80c3fe444a425afbb840098de1c (patch) | |
tree | 13df25573134eb7828fb2b128af6a01421bc4f83 | |
parent | b7b24d61e012eefd8bfc510147fca016f347a349 (diff) | |
download | busybox-w32-465874f3a31da80c3fe444a425afbb840098de1c.tar.gz busybox-w32-465874f3a31da80c3fe444a425afbb840098de1c.tar.bz2 busybox-w32-465874f3a31da80c3fe444a425afbb840098de1c.zip |
- use proper macros to print intmax_t.
PRIuMAX and PRIxMAX are defined in inttypes depending on the wordsize.
-rw-r--r-- | coreutils/stat.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/coreutils/stat.c b/coreutils/stat.c index 36e0dadf3..30a2a625b 100644 --- a/coreutils/stat.c +++ b/coreutils/stat.c | |||
@@ -466,7 +466,7 @@ static int do_stat(char const *filename, char const *format) | |||
466 | print_it(format, filename, print_stat, &statbuf); | 466 | print_it(format, filename, print_stat, &statbuf); |
467 | #else | 467 | #else |
468 | if (flags & OPT_TERSE) { | 468 | if (flags & OPT_TERSE) { |
469 | printf("%s %lu %lu %lx %lu %lu %lx %lu %lu %lx %lx %lu %lu %lu %lu\n", | 469 | printf("%s %"PRIuMAX" %"PRIuMAX" %lx %lu %lu %"PRIxMAX" %"PRIuMAX" %lu %lx %lx %lu %lu %lu %lu\n", |
470 | filename, | 470 | filename, |
471 | (uintmax_t) (statbuf.st_size), | 471 | (uintmax_t) (statbuf.st_size), |
472 | (uintmax_t) statbuf.st_blocks, | 472 | (uintmax_t) statbuf.st_blocks, |
@@ -500,8 +500,8 @@ static int do_stat(char const *filename, char const *format) | |||
500 | else | 500 | else |
501 | printf(" File: \"%s\"\n", filename); | 501 | printf(" File: \"%s\"\n", filename); |
502 | 502 | ||
503 | printf(" Size: %-10lu\tBlocks: %-10lu IO Block: %-6lu %s\n" | 503 | printf(" Size: %-10"PRIuMAX"\tBlocks: %-10"PRIuMAX" IO Block: %-6lu %s\n" |
504 | "Device: %lxh/%lud\tInode: %-10lu Links: %-5lu", | 504 | "Device: %"PRIxMAX"h/%"PRIuMAX"d\tInode: %-10"PRIuMAX" Links: %-5lu", |
505 | (uintmax_t) (statbuf.st_size), | 505 | (uintmax_t) (statbuf.st_size), |
506 | (uintmax_t) statbuf.st_blocks, | 506 | (uintmax_t) statbuf.st_blocks, |
507 | (unsigned long int) statbuf.st_blksize, | 507 | (unsigned long int) statbuf.st_blksize, |