summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common/getrlimit.c
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-12-01 20:43:44 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-12-01 20:43:44 +0000
commit8a0b43005ad9ea011b80d66e32b46fb430ddaffb (patch)
tree418818740042c5dbba244bc1efc760c8d29e47a9 /libc/sysdeps/linux/common/getrlimit.c
parent42b161bb716f35948fabd36472fb59cd0a20fa92 (diff)
Hide mostly used functions
Diffstat (limited to 'libc/sysdeps/linux/common/getrlimit.c')
-rw-r--r--libc/sysdeps/linux/common/getrlimit.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/libc/sysdeps/linux/common/getrlimit.c b/libc/sysdeps/linux/common/getrlimit.c
index c84330b03..fef907a03 100644
--- a/libc/sysdeps/linux/common/getrlimit.c
+++ b/libc/sysdeps/linux/common/getrlimit.c
@@ -13,9 +13,10 @@
#ifdef __NR_ugetrlimit
#define __NR___ugetrlimit __NR_ugetrlimit
-attribute_hidden _syscall2(int, __ugetrlimit, enum __rlimit_resource, resource,
+static inline
+_syscall2(int, __ugetrlimit, enum __rlimit_resource, resource,
struct rlimit *, rlim);
-int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
+int attribute_hidden __getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
{
return (__ugetrlimit(resource, rlimits));
}
@@ -23,15 +24,15 @@ int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
#else /* __NR_ugetrlimit */
/* Only include the old getrlimit if the new one (ugetrlimit) is not around */
-#define __NR___getrlimit __NR_getrlimit
+#define __NR___syscall_getrlimit __NR_getrlimit
static inline
-_syscall2(int, __getrlimit, int, resource, struct rlimit *, rlim);
+_syscall2(int, __syscall_getrlimit, int, resource, struct rlimit *, rlim);
-int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
+int attribute_hidden __getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
{
int result;
- result = __getrlimit(resource, rlimits);
+ result = __syscall_getrlimit(resource, rlimits);
if (result == -1)
return result;
@@ -45,3 +46,5 @@ int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits)
return result;
}
#endif
+
+strong_alias(__getrlimit,getrlimit)