svn commit: r259407 - head/sys/kern

Mateusz Guzik mjg at FreeBSD.org
Sun Dec 15 04:11:44 UTC 2013


Author: mjg
Date: Sun Dec 15 04:11:43 2013
New Revision: 259407
URL: http://svnweb.freebsd.org/changeset/base/259407

Log:
  proc exit: don't take PROC_LOCK while freeing rlimits
  
  Code wishing to check rlimits of some process should check whether it
  is exiting first, which current consumers do.
  
  MFC after:	2 weeks

Modified:
  head/sys/kern/kern_exit.c

Modified: head/sys/kern/kern_exit.c
==============================================================================
--- head/sys/kern/kern_exit.c	Sun Dec 15 03:48:54 2013	(r259406)
+++ head/sys/kern/kern_exit.c	Sun Dec 15 04:11:43 2013	(r259407)
@@ -385,10 +385,8 @@ exit1(struct thread *td, int rv)
 	/*
 	 * Release our limits structure.
 	 */
-	PROC_LOCK(p);
 	plim = p->p_limit;
 	p->p_limit = NULL;
-	PROC_UNLOCK(p);
 	lim_free(plim);
 
 	tidhash_remove(td);


More information about the svn-src-head mailing list