projects
/
oweals
/
busybox.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
date: -R shouldn't use locale
[oweals/busybox.git]
/
coreutils
/
du.c
diff --git
a/coreutils/du.c
b/coreutils/du.c
index efc4490974d66fea34ea27a7e11bf8cc271c4c67..a547b1e14c7bff35c1397d02970758ec25e50df7 100644
(file)
--- a/
coreutils/du.c
+++ b/
coreutils/du.c
@@
-27,7
+27,7
@@
#ifdef CONFIG_FEATURE_HUMAN_READABLE
# ifdef CONFIG_FEATURE_DU_DEFAULT_BLOCKSIZE_1K
#ifdef CONFIG_FEATURE_HUMAN_READABLE
# ifdef CONFIG_FEATURE_DU_DEFAULT_BLOCKSIZE_1K
-static unsigned long disp_hr =
KILOBYTE
;
+static unsigned long disp_hr =
1024
;
# else
static unsigned long disp_hr = 512;
# endif
# else
static unsigned long disp_hr = 512;
# endif
@@
-56,14
+56,14
@@
static void print(long size, const char * const filename)
{
/* TODO - May not want to defer error checking here. */
#ifdef CONFIG_FEATURE_HUMAN_READABLE
{
/* TODO - May not want to defer error checking here. */
#ifdef CONFIG_FEATURE_HUMAN_READABLE
-
bb_
printf("%s\t%s\n", make_human_readable_str(size, 512, disp_hr),
+ printf("%s\t%s\n", make_human_readable_str(size, 512, disp_hr),
filename);
#else
if (disp_k) {
size++;
size >>= 1;
}
filename);
#else
if (disp_k) {
size++;
size >>= 1;
}
-
bb_
printf("%ld\t%s\n", size, filename);
+ printf("%ld\t%s\n", size, filename);
#endif
}
#endif
}
@@
-180,11
+180,11
@@
int du_main(int argc, char **argv)
}
if((opt & (1 << 10))) {
/* -m opt */
}
if((opt & (1 << 10))) {
/* -m opt */
- disp_hr =
MEGABYTE
;
+ disp_hr =
1024*1024
;
}
if((opt & (1 << 2))) {
/* -k opt */
}
if((opt & (1 << 2))) {
/* -k opt */
-
disp_hr = KILOBYTE
;
+
disp_hr = 1024
;
}
#else
opt_complementary = "H-L:L-H:s-d:d-s";
}
#else
opt_complementary = "H-L:L-H:s-d:d-s";
@@
-246,5
+246,5
@@
int du_main(int argc, char **argv)
print(total, "total");
}
print(total, "total");
}
-
bb_
fflush_stdout_and_exit(status);
+ fflush_stdout_and_exit(status);
}
}