summaryrefslogtreecommitdiff
path: root/sysdeps/posix/sigwait.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/posix/sigwait.c')
-rw-r--r--sysdeps/posix/sigwait.c16
1 files changed, 4 insertions, 12 deletions
diff --git a/sysdeps/posix/sigwait.c b/sysdeps/posix/sigwait.c
index 4ff9d847d4..675e59fd7a 100644
--- a/sysdeps/posix/sigwait.c
+++ b/sysdeps/posix/sigwait.c
@@ -1,5 +1,5 @@
/* Implementation of sigwait function from POSIX.1c.
- Copyright (C) 1996-2018 Free Software Foundation, Inc.
+ Copyright (C) 1996-2019 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -15,7 +15,7 @@
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
+ <https://www.gnu.org/licenses/>. */
#include <errno.h>
#include <signal.h>
@@ -85,16 +85,8 @@ do_sigwait (const sigset_t *set, int *sig)
int
__sigwait (const sigset_t *set, int *sig)
{
- if (SINGLE_THREAD_P)
- return do_sigwait (set, sig);
-
- int oldtype = LIBC_CANCEL_ASYNC ();
-
- int result = do_sigwait (set, sig);
-
- LIBC_CANCEL_RESET (oldtype);
-
- return result;
+ /* __sigsuspend should be a cancellation point. */
+ return do_sigitid (idtype, id, infop, options);
}
libc_hidden_def (__sigwait)
weak_alias (__sigwait, sigwait)