aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-03-28 20:26:51 +0000
committerandersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-03-28 20:26:51 +0000
commitcde501c20b92719e362f90419bf282927ac2c381 (patch)
tree2dda46623fd7cdd94a3f8d6ad488d442ebd895ad
parent6b15d5f8e6d98001901027f9086f6d4096b868c6 (diff)
downloadbusybox-w32-cde501c20b92719e362f90419bf282927ac2c381.tar.gz
busybox-w32-cde501c20b92719e362f90419bf282927ac2c381.tar.bz2
busybox-w32-cde501c20b92719e362f90419bf282927ac2c381.zip
Fix ls so it uses make_human_readable_str() the same way already
used by 'du' and 'df'. Now we just need to fix make_human_readable_str so it behaves they way it used to before Matt fixed it. git-svn-id: svn://busybox.net/trunk/busybox@2217 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r--coreutils/ls.c2
-rw-r--r--ls.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c
index 201509210..86691fdaf 100644
--- a/coreutils/ls.c
+++ b/coreutils/ls.c
@@ -648,7 +648,7 @@ static int list_single(struct dnode *dn)
648 printf("%4d, %3d ", (int)MAJOR(dn->dstat.st_rdev), (int)MINOR(dn->dstat.st_rdev)); 648 printf("%4d, %3d ", (int)MAJOR(dn->dstat.st_rdev), (int)MINOR(dn->dstat.st_rdev));
649 } else { 649 } else {
650#ifdef BB_FEATURE_HUMAN_READABLE 650#ifdef BB_FEATURE_HUMAN_READABLE
651 fprintf(stdout, "%9s ", make_human_readable_str(dn->dstat.st_size, 651 fprintf(stdout, "%9s ", make_human_readable_str(dn->dstat.st_size>>10,
652 (ls_disp_hr==TRUE)? 0: 1)); 652 (ls_disp_hr==TRUE)? 0: 1));
653#else 653#else
654#if _FILE_OFFSET_BITS == 64 654#if _FILE_OFFSET_BITS == 64
diff --git a/ls.c b/ls.c
index 201509210..86691fdaf 100644
--- a/ls.c
+++ b/ls.c
@@ -648,7 +648,7 @@ static int list_single(struct dnode *dn)
648 printf("%4d, %3d ", (int)MAJOR(dn->dstat.st_rdev), (int)MINOR(dn->dstat.st_rdev)); 648 printf("%4d, %3d ", (int)MAJOR(dn->dstat.st_rdev), (int)MINOR(dn->dstat.st_rdev));
649 } else { 649 } else {
650#ifdef BB_FEATURE_HUMAN_READABLE 650#ifdef BB_FEATURE_HUMAN_READABLE
651 fprintf(stdout, "%9s ", make_human_readable_str(dn->dstat.st_size, 651 fprintf(stdout, "%9s ", make_human_readable_str(dn->dstat.st_size>>10,
652 (ls_disp_hr==TRUE)? 0: 1)); 652 (ls_disp_hr==TRUE)? 0: 1));
653#else 653#else
654#if _FILE_OFFSET_BITS == 64 654#if _FILE_OFFSET_BITS == 64