From 2e5bc87f49cfbc419c1bd5ae183851fe72fa453d Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Thu, 21 Jul 2005 22:28:07 +0000 Subject: [PATCH] default unsupported to unlimited --- src/sigar.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/sigar.c b/src/sigar.c index ed084e27..55b2774f 100644 --- a/src/sigar.c +++ b/src/sigar.c @@ -979,12 +979,14 @@ int sigar_resource_limit_get(sigar_t *sigar, if ((r->resource == RLIMIT_UNSUPPORTED) || (getrlimit(r->resource, &rl) != 0)) { - rl.rlim_cur = SIGAR_FIELD_NOTIMPL; - rl.rlim_max = SIGAR_FIELD_NOTIMPL; + rl.rlim_cur = RLIM_INFINITY; + rl.rlim_max = RLIM_INFINITY; + } + else { + RlimitScale(rl.rlim_cur); + RlimitScale(rl.rlim_max); } - RlimitScale(rl.rlim_cur); - RlimitScale(rl.rlim_max); RlimitSet(rlimit, r->cur, rl.rlim_cur); RlimitSet(rlimit, r->max, rl.rlim_max); }