aboutsummaryrefslogtreecommitdiff
path: root/toys/other/stat.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2015-10-20 23:35:06 -0500
committerRob Landley <rob@landley.net>2015-10-20 23:35:06 -0500
commitd7e85a7c37e2f7248b8b8c367254abcb6557fd6e (patch)
treec1b47e3b724c5ac3d5c6c3c9a66c439c374387c3 /toys/other/stat.c
parent196e8c0e34e2ccad657f331be9f07e784a041589 (diff)
downloadtoybox-d7e85a7c37e2f7248b8b8c367254abcb6557fd6e.tar.gz
Move d/h units from %d %D output to default format string.
Diffstat (limited to 'toys/other/stat.c')
-rw-r--r--toys/other/stat.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/toys/other/stat.c b/toys/other/stat.c
index d43a8393..fe522b08 100644
--- a/toys/other/stat.c
+++ b/toys/other/stat.c
@@ -70,8 +70,8 @@ static void print_stat(char type)
xprintf("%s", str);
} else if (type == 'b') xprintf("%llu", stat->st_blocks);
else if (type == 'B') xprintf("%lu", stat->st_blksize);
- else if (type == 'd') xprintf("%ldd", stat->st_dev);
- else if (type == 'D') xprintf("%llxh", stat->st_dev);
+ else if (type == 'd') xprintf("%ld", stat->st_dev);
+ else if (type == 'D') xprintf("%llx", stat->st_dev);
else if (type == 'f') xprintf("%lx", stat->st_mode);
else if (type == 'F') {
char *t = "character device\0directory\0block device\0" \
@@ -146,7 +146,7 @@ void stat_main(void)
"Blocks: Total: %b\tFree: %f\tAvailable: %a\n"
"Inodes: Total: %c\tFree: %d"
: " File: %N\n Size: %s\t Blocks: %b\t IO Blocks: %B\t%F\n"
- "Device: %D\t Inode: %i\t Links: %h\n"
+ "Device: %Dh/%dd\t Inode: %i\t Links: %h\n"
"Access: (%a/%A)\tUid: (%u/%U)\tGid: (%g/%G)\n"
"Access: %x\nModify: %y\nChange: %z";