top: Impose a minimum on Screen_cols.
The safety of the critical function task_show() depends on the sanity of Screen_cols. Just copy the tests on w_cols to Screen_cols (from the same function adj_geometry()).
This commit is contained in:
parent
b4d068e624
commit
a71ac048e6
@ -1975,7 +1975,8 @@ static void adj_geometry (void) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// we might disappoint some folks (but they'll deserve it)
|
// we might disappoint some folks (but they'll deserve it)
|
||||||
if (SCREENMAX < Screen_cols) Screen_cols = SCREENMAX;
|
if (Screen_cols > SCREENMAX) Screen_cols = SCREENMAX;
|
||||||
|
if (Screen_cols < W_MIN_COL) Screen_cols = W_MIN_COL;
|
||||||
|
|
||||||
if (!w_set) {
|
if (!w_set) {
|
||||||
if (Width_mode > 0) // -w with arg, we'll try to honor
|
if (Width_mode > 0) // -w with arg, we'll try to honor
|
||||||
|
Loading…
Reference in New Issue
Block a user