aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/mach/hurd/setresgid.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/mach/hurd/setresgid.c')
-rw-r--r--sysdeps/mach/hurd/setresgid.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sysdeps/mach/hurd/setresgid.c b/sysdeps/mach/hurd/setresgid.c
index 8ccfd93c80..64b6840cc8 100644
--- a/sysdeps/mach/hurd/setresgid.c
+++ b/sysdeps/mach/hurd/setresgid.c
@@ -29,6 +29,7 @@ __setresgid (gid_t rgid, gid_t egid, gid_t sgid)
auth_t newauth;
error_t err;
+retry:
HURD_CRITICAL_BEGIN;
__mutex_lock (&_hurd_id.lock);
err = _hurd_check_ids ();
@@ -110,6 +111,9 @@ __setresgid (gid_t rgid, gid_t egid, gid_t sgid)
}
__mutex_unlock (&_hurd_id.lock);
HURD_CRITICAL_END;
+ if (err == EINTR)
+ /* Got a signal while inside an RPC of the critical section, retry again */
+ goto retry;
if (err)
return __hurd_fail (err);