summaryrefslogtreecommitdiffstats
path: root/commands/ls.c
diff options
context:
space:
mode:
authorAntony Pavlov <antonynpavlov@gmail.com>2015-10-02 07:56:51 +0300
committerSascha Hauer <s.hauer@pengutronix.de>2015-10-02 09:12:36 +0200
commit1c9e671462ad4f4e294e962417e122da2a762e65 (patch)
tree3dad3b1aef93e826dfd21d3b89d819cf4efa9d85 /commands/ls.c
parente69b95fec3a005c7eced9e9d5d181f600f943af2 (diff)
downloadbarebox-1c9e671462ad4f4e294e962417e122da2a762e65.tar.gz
commands: ls: use 14 digits for filesize
10 digits are not enough for modern SATA/USB storages. E.g.: barebox> ls -l /dev/ cr-------- 500107862016 ata0 cr-------- 33554432 ata0.0 cr-------- 500073258496 ata0.1 cr-------- 32224837632 disk0 cr-------- 67108864 disk0.0 cr-------- 32156680192 disk0.1 14 digits look much better. E.g.: barebox> ls -l /dev/ cr-------- 500107862016 ata0 cr-------- 33554432 ata0.0 cr-------- 500073258496 ata0.1 cr-------- 32224837632 disk0 cr-------- 67108864 disk0.0 cr-------- 32156680192 disk0.1 Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'commands/ls.c')
-rw-r--r--commands/ls.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/commands/ls.c b/commands/ls.c
index 1a5925d..09437af 100644
--- a/commands/ls.c
+++ b/commands/ls.c
@@ -32,7 +32,7 @@ static void ls_one(const char *path, const char* fullname, struct stat *s)
unsigned int namelen = strlen(path);
mkmodestr(s->st_mode, modestr);
- printf("%s %10llu %*.*s", modestr, s->st_size, namelen, namelen, path);
+ printf("%s %14llu %*.*s", modestr, s->st_size, namelen, namelen, path);
if (S_ISLNK(s->st_mode)) {
char realname[PATH_MAX];