Fix sysinstall(8) and sysupgrade(8) requiring tcgetwincurpos.

This commit is contained in:
Jonas 'Sortie' Termansen 2016-11-19 16:34:21 +01:00
parent e1c64ec92d
commit 1de75a6135
1 changed files with 4 additions and 4 deletions

View File

@ -52,11 +52,11 @@ void text(const char* str)
struct winsize ws;
if ( tcgetwinsize(1, &ws) < 0 )
err(2, "tcgetwinsize");
struct wincurpos wcp;
if ( tcgetwincurpos(1, &wcp) < 0 )
err(2, "tcgetwinsize");
size_t columns = ws.ws_col;
size_t column = wcp.wcp_col;
size_t column = 0;
struct wincurpos wcp;
if ( tcgetwincurpos(1, &wcp) == 0 )
column = wcp.wcp_col;
bool blank = false;
while ( str[0] )
{