Rename sysexits_.h to sysexits.in.h.
[gnulib.git] / lib / sigprocmask.c
index 149d270..9649f8b 100644 (file)
@@ -1,5 +1,5 @@
 /* POSIX compatible signal blocking.
-   Copyright (C) 2006 Free Software Foundation, Inc.
+   Copyright (C) 2006-2007 Free Software Foundation, Inc.
    Written by Bruno Haible <bruno@clisp.org>, 2006.
 
    This program is free software; you can redistribute it and/or modify
@@ -19,7 +19,7 @@
 #include <config.h>
 
 /* Specification.  */
-#include "sigprocmask.h"
+#include <signal.h>
 
 #include <errno.h>
 #include <stdint.h>
@@ -178,7 +178,7 @@ sigprocmask (int operation, const sigset_t *set, sigset_t *old_set)
              received[sig] = 0;
 
          for (sig = 0; sig < NSIG; sig++)
-           if (received[NSIG])
+           if (received[sig])
              {
                #if HAVE_RAISE
                raise (sig);