summaryrefslogtreecommitdiff
path: root/coreutils/ls.c
diff options
context:
space:
mode:
Diffstat (limited to 'coreutils/ls.c')
-rw-r--r--coreutils/ls.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c
index f7fa9a1..8b5065a 100644
--- a/coreutils/ls.c
+++ b/coreutils/ls.c
@@ -982,7 +982,7 @@ extern int ls_main(int argc, char **argv)
#ifdef CONFIG_FEATURE_AUTOWIDTH
/* Obtain the terminal width. */
- get_terminal_width_height(0, &terminal_width, NULL);
+ get_terminal_width_height(fileno(stdout), &terminal_width, NULL);
/* Go one less... */
terminal_width--;
#endif