about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2007-12-17 09:41:08 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2007-12-17 09:41:08 +0000
commit2fe664de462b14e1b7aa96d9a49dc8be32556576 (patch)
treed7dada5b355a80d5a1bb6c7a209de2cb4caecb00 /Src
parent6176062298c7efcebaf5458c63a125de93294bc9 (diff)
downloadzsh-2fe664de462b14e1b7aa96d9a49dc8be32556576.tar.gz
zsh-2fe664de462b14e1b7aa96d9a49dc8be32556576.tar.xz
zsh-2fe664de462b14e1b7aa96d9a49dc8be32556576.zip
Wayne: 24273: curses macros dont return a value
Diffstat (limited to 'Src')
-rw-r--r--Src/Modules/curses.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/Src/Modules/curses.c b/Src/Modules/curses.c
index 4f5cbd80b..0649f5750 100644
--- a/Src/Modules/curses.c
+++ b/Src/Modules/curses.c
@@ -1329,9 +1329,14 @@ zccmd_position(const char *nam, char **args)
     w = (ZCWin)getdata(node);
 
     /* Look no pointers:  these are macros. */
-    if (getyx(w->win, intarr[0], intarr[1]) == ERR ||
-	getbegyx(w->win, intarr[2], intarr[3]) == ERR ||
-	getmaxyx(w->win, intarr[4], intarr[5]) == ERR)
+    getyx(w->win, intarr[0], intarr[1]);
+    if (intarr[0] == -1)
+	return 1;
+    getbegyx(w->win, intarr[2], intarr[3]);
+    if (intarr[2] == -1)
+	return 1;
+    getmaxyx(w->win, intarr[4], intarr[5]);
+    if (intarr[4] == -1)
 	return 1;
 
     array = (char **)zalloc(7*sizeof(char *));