From: Daniel Hokka Zakrisson Date: Sat, 4 Nov 2006 19:36:06 +0000 (+0000) Subject: Reset all limits that aren't configured. X-Git-Tag: release-0.30.212~53 X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=29fd9845a8128b8e7f6c3828da14d724f8e748f7;p=util-vserver.git Reset all limits that aren't configured. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2370 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- diff --git a/src/exec-ulimit.c b/src/exec-ulimit.c index a487963..7219a9e 100644 --- a/src/exec-ulimit.c +++ b/src/exec-ulimit.c @@ -177,6 +177,10 @@ int main(int argc, char *argv[]) Egetrlimit(LIMITS[i].code, &limit); if (readSingleLimit(&limit, LIMITS[i].fname)) Esetrlimit(LIMITS[i].code, &limit); + else { + limit.rlim_cur = limit.rlim_max = RLIM_INFINITY; + Esetrlimit(LIMITS[i].code, &limit); + } } Efchdir(cur_fd); }