Lines Matching refs:which
237 limit_value(int which, char *arg, rlim64_t *limit)
248 if (which == RLIMIT_CPU && strchr(arg, ':') != NULL) {
278 if (which == RLIMIT_CPU)
285 if (which == RLIMIT_CPU)
292 switch (which) {
316 parse_limits(int which, char *arg)
321 struct rlimit64 *rp = &rlimit[which];
328 set_current[which] = FALSE;
330 if (limit_value(which, soft, &rp->rlim_cur) != 0)
332 set_current[which] = TRUE;
337 set_maximum[which] = FALSE;
339 if (limit_value(which, hard, &rp->rlim_max) != 0)
341 set_maximum[which] = TRUE;
343 if (set_current[which] && set_maximum[which] &&
470 set_one_limit(struct ps_prochandle *Pr, int which, rlim64_t cur, rlim64_t max)
478 if (pr_getrlimit64(Pr, which, &rlim) != 0) {
485 if (!set_current[which])
487 if (!set_maximum[which])
549 if (pr_setrlimit64(Pr, which, &rlim) != 0) {
591 int which;
594 for (which = 0; which < RLIM_NLIMITS; which++) {
595 if (set_current[which] || set_maximum[which]) {
596 if (set_one_limit(Pr, which, rlimit[which].rlim_cur,
597 rlimit[which].rlim_max) != 0)