aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2003-06-08 20:24:04 +0000
committerUlrich Drepper <drepper@redhat.com>2003-06-08 20:24:04 +0000
commitf0da6a7d5a4fbfc2b114b1fc17f4368e4fee7f8d (patch)
treed410468f75fd62a47fdba73ddafe10e95c04a250
parentecf7955d551d9527b2b6bf0a489b236f9da763b9 (diff)
downloadglibc-f0da6a7d5a4fbfc2b114b1fc17f4368e4fee7f8d.zip
glibc-f0da6a7d5a4fbfc2b114b1fc17f4368e4fee7f8d.tar.gz
glibc-f0da6a7d5a4fbfc2b114b1fc17f4368e4fee7f8d.tar.bz2
Update.
* sysdeps/unix/sysv/linux/i386/setregid.c (__setregid): Make POSIX compliant. Don't change sgid. * sysdeps/unix/sysv/linux/i386/setreuid.c (__setreuid): Make POSIX compliant. Don't change suid.
-rw-r--r--ChangeLog5
-rw-r--r--sysdeps/unix/sysv/linux/i386/setregid.c8
-rw-r--r--sysdeps/unix/sysv/linux/i386/setreuid.c8
3 files changed, 13 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index 706e094..de87ccd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2003-06-08 Ulrich Drepper <drepper@redhat.com>
+ * sysdeps/unix/sysv/linux/i386/setregid.c (__setregid): Make POSIX
+ compliant. Don't change sgid.
+ * sysdeps/unix/sysv/linux/i386/setreuid.c (__setreuid): Make POSIX
+ compliant. Don't change suid.
+
* config.h.in: Add have-forced-unwind.
* configure.in: Add AC_SUBST(libc_cv_forced_unwind).
diff --git a/sysdeps/unix/sysv/linux/i386/setregid.c b/sysdeps/unix/sysv/linux/i386/setregid.c
index 4f89731..d49bf47 100644
--- a/sysdeps/unix/sysv/linux/i386/setregid.c
+++ b/sysdeps/unix/sysv/linux/i386/setregid.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2003 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -42,7 +42,7 @@ int
__setregid (gid_t rgid, gid_t egid)
{
#if __ASSUME_32BITUIDS > 0
- return INLINE_SYSCALL (setregid32, 2, rgid, egid);
+ return INLINE_SYSCALL (setresgid32, 3, rgid, egid, -1);
#else
# ifdef __NR_setregid32
if (__libc_missing_32bit_uids <= 0)
@@ -50,7 +50,7 @@ __setregid (gid_t rgid, gid_t egid)
int result;
int saved_errno = errno;
- result = INLINE_SYSCALL (setregid32, 2, rgid, egid);
+ result = INLINE_SYSCALL (setresgid32, 3, rgid, egid, -1);
if (result == 0 || errno != ENOSYS)
return result;
@@ -66,7 +66,7 @@ __setregid (gid_t rgid, gid_t egid)
return -1;
}
- return INLINE_SYSCALL (setregid, 2, rgid, egid);
+ return INLINE_SYSCALL (setresgid, 3, rgid, egid, -1);
#endif
}
weak_alias (__setregid, setregid)
diff --git a/sysdeps/unix/sysv/linux/i386/setreuid.c b/sysdeps/unix/sysv/linux/i386/setreuid.c
index 43263fb..04496c8 100644
--- a/sysdeps/unix/sysv/linux/i386/setreuid.c
+++ b/sysdeps/unix/sysv/linux/i386/setreuid.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2003 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -42,7 +42,7 @@ int
__setreuid (uid_t ruid, uid_t euid)
{
#if __ASSUME_32BITUIDS > 0
- return INLINE_SYSCALL (setreuid32, 2, ruid, euid);
+ return INLINE_SYSCALL (setresuid32, 3, ruid, euid, -1);
#else
# ifdef __NR_setreuid32
if (__libc_missing_32bit_uids <= 0)
@@ -50,7 +50,7 @@ __setreuid (uid_t ruid, uid_t euid)
int result;
int saved_errno = errno;
- result = INLINE_SYSCALL (setreuid32, 2, ruid, euid);
+ result = INLINE_SYSCALL (setresuid32, 3, ruid, euid, -1);
if (result == 0 || errno != ENOSYS)
return result;
@@ -66,7 +66,7 @@ __setreuid (uid_t ruid, uid_t euid)
return -1;
}
- return INLINE_SYSCALL (setreuid, 2, ruid, euid);
+ return INLINE_SYSCALL (setresuid, 3, ruid, euid, -1);
#endif
}
weak_alias (__setreuid, setreuid)