summaryrefslogtreecommitdiffstats
path: root/lib/libcurses/tty/hashmap.c
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>1999-03-18 16:46:57 +0000
committermillert <millert@openbsd.org>1999-03-18 16:46:57 +0000
commite7bb0ef19c4dc6ebd38c4dd4fe59d84570304639 (patch)
tree4b0c0c933459ba5a6b5a2399078ff006a65600dc /lib/libcurses/tty/hashmap.c
parenttypo; nash@mcs.net (diff)
downloadwireguard-openbsd-e7bb0ef19c4dc6ebd38c4dd4fe59d84570304639.tar.xz
wireguard-openbsd-e7bb0ef19c4dc6ebd38c4dd4fe59d84570304639.zip
ncurses-4.2-990318
Diffstat (limited to 'lib/libcurses/tty/hashmap.c')
-rw-r--r--lib/libcurses/tty/hashmap.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libcurses/tty/hashmap.c b/lib/libcurses/tty/hashmap.c
index a7999113814..25ea2478a84 100644
--- a/lib/libcurses/tty/hashmap.c
+++ b/lib/libcurses/tty/hashmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hashmap.c,v 1.3 1999/03/16 15:25:08 millert Exp $ */
+/* $OpenBSD: hashmap.c,v 1.4 1999/03/18 16:46:58 millert Exp $ */
/****************************************************************************
* Copyright (c) 1998 Free Software Foundation, Inc. *
@@ -72,7 +72,7 @@ AUTHOR
#include <curses.priv.h>
#include <term.h> /* for back_color_erase */
-MODULE_ID("$From: hashmap.c,v 1.32 1999/03/16 11:40:53 Alexander.V.Lukyanov Exp $")
+MODULE_ID("$From: hashmap.c,v 1.33 1999/03/18 02:09:45 Alexander.V.Lukyanov Exp $")
#ifdef HASHDEBUG
@@ -396,7 +396,7 @@ void _nc_hash_map(void)
while (i < screen_lines && OLDNUM(i) != _NEWINDEX && OLDNUM(i) - i == shift)
i++;
size = i - start;
- if (size < 3 || size+size/8 < abs(shift))
+ if (size < 3 || size+min(size/8,2) < abs(shift))
{
while (start < i)
{