about summary refs log tree commit diff
diff options
context:
space:
mode:
authorClint Adams <clint@users.sourceforge.net>2007-10-15 13:30:07 +0000
committerClint Adams <clint@users.sourceforge.net>2007-10-15 13:30:07 +0000
commit951c8cca0f49492aa51dfcd622bd1a0b87e422cd (patch)
tree59a5a89ead53b538297a4a05253edca7130c726a
parent48139337d3baa493d1dcb3601b5cde03891a88c6 (diff)
downloadzsh-951c8cca0f49492aa51dfcd622bd1a0b87e422cd.tar.gz
zsh-951c8cca0f49492aa51dfcd622bd1a0b87e422cd.tar.xz
zsh-951c8cca0f49492aa51dfcd622bd1a0b87e422cd.zip
23957: minor fixes.
-rw-r--r--ChangeLog4
-rw-r--r--Doc/Zsh/mod_curses.yo3
-rw-r--r--Src/Modules/curses.c2
3 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 6fc4b3870..28701584d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2007-10-15  Clint Adams  <clint@zsh.org>
+
+	* 23957: Doc/Zsh/mod_curses.yo, Src/Modules/curses.c: minor fixes.
+
 2007-10-14  Clint Adams  <clint@zsh.org>
 
 	* unposted: Doc/Zsh/.distfiles, Src/Modules/.distfiles: update for
diff --git a/Doc/Zsh/mod_curses.yo b/Doc/Zsh/mod_curses.yo
index 82b95ff51..a44608289 100644
--- a/Doc/Zsh/mod_curses.yo
+++ b/Doc/Zsh/mod_curses.yo
@@ -26,7 +26,8 @@ The tt(-r) command will refresh window var(targetwin); this is necessary to
 make any pending changes (such as characters you have prepared for output
 with tt(-c)) visible on the screen.
 
-tt(-m) moves var(targetwin) to new coordinates var(new_y) and var(new_x).
+tt(-m) moves the cursor position in var(targetwin) to new coordinates
+var(new_y) and var(new_x).
 
 Outputting characters and strings are achieved by tt(-c) and tt(-s)
 respectively.
diff --git a/Src/Modules/curses.c b/Src/Modules/curses.c
index bfcbeca01..1cc711a2d 100644
--- a/Src/Modules/curses.c
+++ b/Src/Modules/curses.c
@@ -78,7 +78,7 @@ zcurses_validate_window(char *win, int criteria)
 
     target = (unsigned)atoi(win);
 
-    if (target > ZCURSES_MAX_WINDOWS) {
+    if (target > ZCURSES_MAX_WINDOWS || target < 1) {
 	zc_errno = ZCURSES_ERANGE;
 	return -1;
     }