tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: How to prevent a mutex being _enter()ed from being _destroy()ed?



> Date: Mon, 13 Aug 2018 14:19:42 +0000
> From: Taylor R Campbell <campbell+netbsd-tech-kern%mumble.net@localhost>
> 
> If you are running with DIAGNOSTIC off, then KASSERT(fp->f_count != 0)
> in unp_gc in netbsd-6 will never panic; instead it may attempt to
> regain a reference too late to a socket file that another thread is in
> the process of closing.  This is PR 39918, and the fix/workaround was
> pulled up to -7 but not to -6.  You could test this hypothesis by
> explicitly writing `if (fp->f_count != 0) panic("...")' there.

Correction: `if (fp->fp_count == 0) panc("...")'.


Home | Main Index | Thread Index | Old Index