diff options
| author | David Nugent <davidn@FreeBSD.org> | 1997-01-21 16:37:01 +0000 |
|---|---|---|
| committer | David Nugent <davidn@FreeBSD.org> | 1997-01-21 16:37:01 +0000 |
| commit | 1273ebf576b8b825fcd851d9794b1df38400b600 (patch) | |
| tree | 92f0a233c6ea515b1723188a2b684628ba7df2ed /sys/kern | |
| parent | 0a98733422756a45b875ae44a9c0c3b36152f560 (diff) | |
Notes
Diffstat (limited to 'sys/kern')
| -rw-r--r-- | sys/kern/kern_exit.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index ac1d95243abe..82c1f8ba4498 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -222,6 +222,11 @@ exit1(p, rv) sp->s_leader = NULL; } fixjobc(p, p->p_pgrp, 0); + if (p->p_limit->p_refcnt > 1 && + (p->p_limit->p_lflags & PL_SHAREMOD) == 0) { + p->p_limit->p_refcnt--; + p->p_limit = limcopy(p->p_limit); + } p->p_rlimit[RLIMIT_FSIZE].rlim_cur = RLIM_INFINITY; (void)acct_process(p); #ifdef KTRACE |
