Date: Tue, 17 Apr 2012 13:44:40 +0000 (UTC) From: Edward Tomasz Napierala <trasz@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r234381 - head/sys/kern Message-ID: <201204171344.q3HDie9x084585@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: trasz Date: Tue Apr 17 13:44:40 2012 New Revision: 234381 URL: http://svn.freebsd.org/changeset/base/234381 Log: Fix panic, triggered like this: "int main() { thr_exit(); }" Submitted by: Mateusz Guzik Modified: head/sys/kern/kern_thr.c Modified: head/sys/kern/kern_thr.c ============================================================================== --- head/sys/kern/kern_thr.c Tue Apr 17 13:28:14 2012 (r234380) +++ head/sys/kern/kern_thr.c Tue Apr 17 13:44:40 2012 (r234381) @@ -317,13 +317,13 @@ sys_thr_exit(struct thread *td, struct t rw_wlock(&tidhash_lock); PROC_LOCK(p); - racct_sub(p, RACCT_NTHR, 1); /* * Shutting down last thread in the proc. This will actually * call exit() in the trampoline when it returns. */ if (p->p_numthreads != 1) { + racct_sub(p, RACCT_NTHR, 1); LIST_REMOVE(td, td_hash); rw_wunlock(&tidhash_lock); tdsigcleanup(td);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201204171344.q3HDie9x084585>