[PATCH v2] Fix segfault when restoring w_alt.cursor

2012-08-10 Thread Michael Spang
Screen can be segfaulted with the following steps: - Start screen - Enable altscreen with ":altscreen on" - Enable caption with ":caption always" - Run vim - Resize the current terminal to one line high - Resize the current terminal to multiple lines high - Quit vim This happens bec

[PATCH v2] Fix segfault when restoring w_alt.cursor

2012-08-10 Thread Michael Spang
Screen can be segfaulted with the following steps: - Start screen - Enable altscreen with ":altscreen on" - Enable caption with ":caption always" - Run vim - Resize the current terminal to one line high - Resize the current terminal to multiple lines high - Quit vim This happens bec

[PATCH] Forbid creation of zero-height canvas

2012-08-10 Thread Michael Spang
The code is not prepared to handle a canvas with no lines. One way to segfault screen with a 0-line canvas is: - Start screen - Enable caption with ":caption always" - Run vim - Resize the current terminal to one line high - Resize the current terminal to multiple lines high - Quit vim