1 | --- trunk/base/src/pextlib1.0/tracelib.c:20130503 2012-11-27 03:45:59.000000000 +0000 |
---|
2 | +++ trunk/base/src/pextlib1.0/tracelib.c 2013-05-03 23:58:11.000000000 +0000 |
---|
3 | @@ -430,11 +430,11 @@ |
---|
4 | |
---|
5 | interp=in; |
---|
6 | |
---|
7 | - rl.rlim_cur=rl.rlim_max=RLIM_INFINITY; |
---|
8 | #if defined(__APPLE__) && defined(OPEN_MAX) |
---|
9 | - if (OPEN_MAX < rl.rlim_cur) |
---|
10 | - rl.rlim_cur = OPEN_MAX; |
---|
11 | + if (rl.rlim_max > OPEN_MAX) |
---|
12 | + rl.rlim_max = OPEN_MAX; |
---|
13 | #endif |
---|
14 | + rl.rlim_cur = rl.rlim_max; |
---|
15 | if(setrlimit(RLIMIT_NOFILE, &rl)==-1) |
---|
16 | { |
---|
17 | ui_warn("setrlimit failed (%d)", errno); |
---|