1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-01-19 11:31:26 +01:00

30530,30533: fix problems with COLUMNS or LINES < 1, and related issues

This commit is contained in:
Bart Schaefer 2012-06-27 07:10:29 +00:00
parent 71052cb69c
commit 9af1cd4722
3 changed files with 16 additions and 3 deletions

View file

@ -1,3 +1,16 @@
2012-06-26 Barton E. Schaefer <schaefer@zsh.org>
* 30533: Src/utils.c: when processing a change in the value of
COLUMNS, do not assert the change into the tty driver winsize.
The code for this was dead the whole time IPDEF5 was broken and
this seems a bad time to make it live; besides which it is not
consistent about the handling of LINES (which is ignored when
changed by itself, but would be asserted when COLUMNS changes).
* 30530: Src/params.c: fix long-broken IPDEF5 definition to use
the GSU struct, thus fixing problems with values of LINES or
COLUMNS less than 1.
2012-06-21 Peter Stephenson <pws@csr.com>
* Danek (plus .distfiles changes): 30520:
@ -16411,5 +16424,5 @@
*****************************************************
* This is used by the shell to define $ZSH_PATCHLEVEL
* $Revision: 1.5674 $
* $Revision: 1.5675 $
*****************************************************

View file

@ -315,7 +315,7 @@ IPDEF4("LINENO", &lineno),
IPDEF4("PPID", &ppid),
IPDEF4("ZSH_SUBSHELL", &zsh_subshell),
#define IPDEF5(A,B,F) {{NULL,A,PM_INTEGER|PM_SPECIAL},BR((void *)B),GSU(varinteger_gsu),10,0,NULL,NULL,NULL,0}
#define IPDEF5(A,B,F) {{NULL,A,PM_INTEGER|PM_SPECIAL},BR((void *)B),GSU(F),10,0,NULL,NULL,NULL,0}
IPDEF5("COLUMNS", &zterm_columns, zlevar_gsu),
IPDEF5("LINES", &zterm_lines, zlevar_gsu),
IPDEF5("OPTIND", &zoptind, varinteger_gsu),

View file

@ -1686,7 +1686,7 @@ adjustwinsize(int from)
(shttyinfo.winsize.ws_row != ttyrows ||
shttyinfo.winsize.ws_col != ttycols)) {
/* shttyinfo.winsize is already set up correctly */
ioctl(SHTTY, TIOCSWINSZ, (char *)&shttyinfo.winsize);
/* ioctl(SHTTY, TIOCSWINSZ, (char *)&shttyinfo.winsize); */
}
#endif /* TIOCGWINSZ */