1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-11 22:31:12 +02:00

(scm_sigaction_for_thread): Correction to signum range

test, avoids SCM_VECTOR_REF outside bounds of signal_handlers on
calling (sigaction NSIG).
This commit is contained in:
Kevin Ryde 2004-04-05 22:46:29 +00:00
parent eac8e0ef86
commit 2e1fc2e8e3

View file

@ -1,4 +1,4 @@
/* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002 Free Software Foundation, Inc.
/* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2004 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@ -299,7 +299,7 @@ SCM_DEFINE (scm_sigaction_for_thread, "sigaction", 1, 3, 0,
SCM old_handler;
SCM_VALIDATE_INUM_COPY (1, signum, csig);
if (csig < 0 || csig > NSIG)
if (csig < 0 || csig >= NSIG)
SCM_OUT_OF_RANGE (1, signum);
#if defined(HAVE_SIGACTION)
#if defined(SA_RESTART) && defined(HAVE_RESTARTABLE_SYSCALLS)