Commit 4d4979c6 authored by Ondřej Zajíček's avatar Ondřej Zajíček

Fixes some potential issues with invalid term size in clients.

parent 33be3ba7
......@@ -148,8 +148,8 @@ input_init(void)
rl_callback_handler_install("bird> ", input_got_line);
// rl_get_screen_size();
term_lns = LINES ? LINES : 25;
term_cls = COLS ? COLS : 80;
term_lns = LINES;
term_cls = COLS;
prompt_active = 1;
......
......@@ -150,11 +150,6 @@ input_init(void)
term_lns = tws.ws_row;
term_cls = tws.ws_col;
}
else
{
term_lns = 25;
term_cls = 80;
}
}
void
......
......@@ -178,6 +178,10 @@ init_commands(void)
}
input_init();
term_lns = (term_lns > 0) ? term_lns : 25;
term_cls = (term_cls > 0) ? term_cls : 80;
init = 0;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment