diff options
Diffstat (limited to 'sysdeps/mach/hurd/waitid.c')
-rw-r--r-- | sysdeps/mach/hurd/waitid.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/sysdeps/mach/hurd/waitid.c b/sysdeps/mach/hurd/waitid.c index 7bbbbdbe54..3a41697140 100644 --- a/sysdeps/mach/hurd/waitid.c +++ b/sysdeps/mach/hurd/waitid.c @@ -52,8 +52,7 @@ __waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options) break; default: invalid: - __set_errno (EINVAL); - return -1; + return __hurd_fail (EINVAL); } /* Technically we're supposed to return EFAULT if infop is bogus, @@ -62,10 +61,7 @@ __waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options) We just check for a null pointer. */ if (infop == NULL) - { - __set_errno (EFAULT); - return -1; - } + return __hurd_fail (EFAULT); cancel_oldtype = LIBC_CANCEL_ASYNC(); #if HURD_INTERFACE_VERSION >= 20201227 |