diff --git a/lib/System/Unix/Program.inc b/lib/System/Unix/Program.inc index 1fe25861e1e..4da1c73fbd1 100644 --- a/lib/System/Unix/Program.inc +++ b/lib/System/Unix/Program.inc @@ -125,11 +125,13 @@ static void SetMemoryLimits (unsigned size) r.rlim_cur = limit; setrlimit (RLIMIT_RSS, &r); #endif +#ifdef RLIMIT_AS // e.g. NetBSD doesn't have it. // Virtual memory. getrlimit (RLIMIT_AS, &r); r.rlim_cur = limit; setrlimit (RLIMIT_AS, &r); #endif +#endif } int