summaryrefslogtreecommitdiffstats
path: root/call
diff options
context:
space:
mode:
Diffstat (limited to 'call')
-rw-r--r--call/menu.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/call/menu.c b/call/menu.c
index 9ad397c..6c0c2d7 100644
--- a/call/menu.c
+++ b/call/menu.c
@@ -62,8 +62,9 @@ void winclose(wint * wtab)
awin_lines = awin->lline - awin->fline;
while (wtab->next != NULL) {
- if (awin->lline >= wtab->fline
- && awin->fline <= wtab->lline) {
+ if (wtab->fline >= 0 && wtab->lline >= 0 &&
+ awin->lline >= wtab->fline &&
+ awin->fline <= wtab->lline) {
if (wtab->fline <= awin->fline) {
if (wtab->lline < awin->lline) {
wtouchln(wtab->ptr,