This patch guards the newly added syscall wrapper prlimit for kernels that predate this feature.
Lance Fredrickson
---
libc/sysdeps/linux/common/prlimit.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libc/sysdeps/linux/common/prlimit.c b/libc/sysdeps/linux/common/prlimit.c
index cdb64ba0d..dbb0de0d3 100644
--- a/libc/sysdeps/linux/common/prlimit.c
+++ b/libc/sysdeps/linux/common/prlimit.c
@@ -18,6 +18,7 @@
#include <sys/resource.h>
#include <sysdep.h>
+#ifdef __NR_prlimit
int
prlimit (__pid_t pid, enum __rlimit_resource resource,
const struct rlimit *new_rlimit, struct rlimit *old_rlimit)
@@ -25,3 +26,4 @@ prlimit (__pid_t pid, enum __rlimit_resource resource,
return INLINE_SYSCALL (prlimit64, 4, pid, resource, new_rlimit,
old_rlimit);
}
+#endif
--
2.20.1