diff options
Diffstat (limited to 'libc/sysdeps/linux/common/geteuid.c')
-rw-r--r-- | libc/sysdeps/linux/common/geteuid.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/libc/sysdeps/linux/common/geteuid.c b/libc/sysdeps/linux/common/geteuid.c index 819a1d65f..247f1bfda 100644 --- a/libc/sysdeps/linux/common/geteuid.c +++ b/libc/sysdeps/linux/common/geteuid.c @@ -12,19 +12,25 @@ libc_hidden_proto(geteuid) -#ifdef __NR_geteuid -#define __NR___syscall_geteuid __NR_geteuid +#if defined(__NR_geteuid32) +# undef __NR_geteuid +# define __NR_geteuid __NR_geteuid32 +_syscall0(uid_t, geteuid); + +#elif defined(__NR_geteuid) +# define __NR___syscall_geteuid __NR_geteuid static inline _syscall0(int, __syscall_geteuid); uid_t geteuid(void) { return (__syscall_geteuid()); } + #else libc_hidden_proto(getuid) - uid_t geteuid(void) { return (getuid()); } #endif + libc_hidden_def(geteuid) |