summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1999-03-18 16:46:59 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1999-03-18 16:46:59 +0000
commit90cb62c80e5235f68fc0fb51de581a1d00aa2921 (patch)
treee3ab4bb909d27f2805ac32b645957efe8c3b1d82
parentca22921cc9890c9dab07b53c84fd6f5cca6574db (diff)
ncurses-4.2-990318
-rw-r--r--lib/libcurses/base/sigaction.c14
-rw-r--r--lib/libcurses/curses.h4
-rw-r--r--lib/libcurses/tty/hashmap.c6
3 files changed, 15 insertions, 9 deletions
diff --git a/lib/libcurses/base/sigaction.c b/lib/libcurses/base/sigaction.c
index cfa5db79b70..b07ee1c333d 100644
--- a/lib/libcurses/base/sigaction.c
+++ b/lib/libcurses/base/sigaction.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sigaction.c,v 1.1 1999/01/18 19:10:07 millert Exp $ */
+/* $OpenBSD: sigaction.c,v 1.2 1999/03/18 16:46:58 millert Exp $ */
/****************************************************************************
* Copyright (c) 1998 Free Software Foundation, Inc. *
@@ -42,7 +42,7 @@
#include <signal.h>
#include <SigAction.h>
-MODULE_ID("$From: sigaction.c,v 1.7 1998/02/11 12:13:53 tom Exp $")
+MODULE_ID("$From: sigaction.c,v 1.8 1999/03/18 02:12:04 tom Exp $")
int
sigaction (int sig, sigaction_t * sigact, sigaction_t * osigact)
@@ -59,7 +59,7 @@ sigemptyset (sigset_t * mask)
int
sigprocmask (int mode, sigset_t * mask, sigset_t * omask)
- {
+{
sigset_t current = sigsetmask(0);
if (omask) *omask = current;
@@ -73,7 +73,7 @@ sigprocmask (int mode, sigset_t * mask, sigset_t * omask)
sigsetmask(current);
return 0;
- }
+}
int
sigsuspend (sigset_t * mask)
@@ -94,6 +94,12 @@ sigaddset (sigset_t * mask, int sig)
*mask |= sigmask (sig);
return 0;
}
+
+int
+sigismember (sigset_t * mask, int sig)
+{
+ return (*mask & sigmask (sig)) != 0;
+}
#else
extern void _nc_sigaction(void); /* quiet's gcc warning */
void _nc_sigaction(void) { } /* nonempty for strict ANSI compilers */
diff --git a/lib/libcurses/curses.h b/lib/libcurses/curses.h
index be2e2a4f954..59db523bf99 100644
--- a/lib/libcurses/curses.h
+++ b/lib/libcurses/curses.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: curses.h,v 1.26 1999/03/16 15:25:08 millert Exp $ */
+/* $OpenBSD: curses.h,v 1.27 1999/03/18 16:46:57 millert Exp $ */
/****************************************************************************
* Copyright (c) 1998 Free Software Foundation, Inc. *
@@ -50,7 +50,7 @@
/* These are defined only in curses.h, and are used for conditional compiles */
#define NCURSES_VERSION_MAJOR 5
#define NCURSES_VERSION_MINOR 0
-#define NCURSES_VERSION_PATCH 990316
+#define NCURSES_VERSION_PATCH 990318
/* This is defined in more than one ncurses header, for identification */
#undef NCURSES_VERSION
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)
{