diff options
-rw-r--r-- | coreutils/df.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/coreutils/df.c b/coreutils/df.c index debb86867..a659353c0 100644 --- a/coreutils/df.c +++ b/coreutils/df.c | |||
@@ -113,6 +113,13 @@ int df_main(int argc UNUSED_PARAM, char **argv) | |||
113 | 113 | ||
114 | init_unicode(); | 114 | init_unicode(); |
115 | 115 | ||
116 | /* From the manpage of df from coreutils-6.10: | ||
117 | * Disk space is shown in 1K blocks by default, unless the environment | ||
118 | * variable POSIXLY_CORRECT is set, in which case 512-byte blocks are used. | ||
119 | */ | ||
120 | if (getenv("POSIXLY_CORRECT")) /* TODO - a new libbb function? */ | ||
121 | df_disp_hr = 512; | ||
122 | |||
116 | opt = getopt32(argv, "^" | 123 | opt = getopt32(argv, "^" |
117 | "kPT" | 124 | "kPT" |
118 | IF_FEATURE_DF_FANCY("aiB:") | 125 | IF_FEATURE_DF_FANCY("aiB:") |
@@ -142,13 +149,6 @@ int df_main(int argc UNUSED_PARAM, char **argv) | |||
142 | got_it: ; | 149 | got_it: ; |
143 | } | 150 | } |
144 | 151 | ||
145 | /* From the manpage of df from coreutils-6.10: | ||
146 | * Disk space is shown in 1K blocks by default, unless the environment | ||
147 | * variable POSIXLY_CORRECT is set, in which case 512-byte blocks are used. | ||
148 | */ | ||
149 | if (getenv("POSIXLY_CORRECT")) /* TODO - a new libbb function? */ | ||
150 | df_disp_hr = 512; | ||
151 | |||
152 | if (opt & OPT_HUMAN) { | 152 | if (opt & OPT_HUMAN) { |
153 | df_disp_hr = 0; | 153 | df_disp_hr = 0; |
154 | disp_units_hdr = " Size"; | 154 | disp_units_hdr = " Size"; |