aboutsummaryrefslogtreecommitdiff
path: root/toys/posix
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2017-02-05 00:44:29 -0600
committerRob Landley <rob@landley.net>2017-02-05 00:44:29 -0600
commit796d873d95e1be63ece2345d0e985a057210c1b9 (patch)
treef170908e1219db0b9573f6021ce2e7f513c0f86b /toys/posix
parentea9dd8ab7f5fd8ead278ed8d4fa2d96c4e4a67b9 (diff)
downloadtoybox-796d873d95e1be63ece2345d0e985a057210c1b9.tar.gz
Default to width 80 when tty size probe fails (ala serial console).
(It was defaulting to 99999 but not FLAG_w, so it tried to _pad_ to 99999.)
Diffstat (limited to 'toys/posix')
-rw-r--r--toys/posix/ps.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/toys/posix/ps.c b/toys/posix/ps.c
index 33ab4945..a28118fa 100644
--- a/toys/posix/ps.c
+++ b/toys/posix/ps.c
@@ -1142,7 +1142,7 @@ static void shared_main(void)
TT.ticks = sysconf(_SC_CLK_TCK);
if (!TT.width) {
- TT.width = (toys.which->name[1] == 's') ? 99999 : 80;
+ TT.width = 80;
TT.height = 25;
terminal_size(&TT.width, &TT.height);
}