From 2f3f26ea1ec581cd24a0778323eb0844f03fd6a3 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Tue, 9 Feb 2016 17:23:31 -0600 Subject: Add ulimit. This isn't a shell builtin, it uses prlimit to target any pid (without -P it defaults to $PPID, so acts like historical ulimit by default). --- lib/portability.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'lib/portability.h') diff --git a/lib/portability.h b/lib/portability.h index eadd9961..53b08704 100644 --- a/lib/portability.h +++ b/lib/portability.h @@ -247,6 +247,16 @@ static inline void endutxent(void) {;} #define O_PATH 010000000 #endif +// Glibc won't give you linux-kernel constants unless you say "no, a BUD lite" +// even though linux has nothing to do with the FSF and never has. +#ifndef F_SETPIPE_SZ +#define F_SETPIPE_SZ 1031 +#endif + +#ifndef F_GETPIPE_SZ +#define F_GETPIPE_SZ 1032 +#endif + #if defined(__SIZEOF_DOUBLE__) && defined(__SIZEOF_LONG__) \ && __SIZEOF_DOUBLE__ <= __SIZEOF_LONG__ typedef double FLOAT; -- cgit v1.2.3