From 15861d228508ea2c177d6ec51dfd9a625cbc4c51 Mon Sep 17 00:00:00 2001 From: Steffen Vogel Date: Tue, 12 Feb 2019 16:17:36 +0100 Subject: [PATCH] terminal: fix intialization of terminal dimensions of no TTY is available --- common/lib/terminal.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/lib/terminal.cpp b/common/lib/terminal.cpp index b5ecf7430..3614e28f9 100644 --- a/common/lib/terminal.cpp +++ b/common/lib/terminal.cpp @@ -34,6 +34,9 @@ Terminal::Terminal() { int ret; + window.ws_row = 0; + window.ws_col = 0; + isTty = isatty(fileno(stdin)); if (isTty) {