Don't forget to destroy the mutex if an error occurs

in the jail() system call.

Submitted by:	Pawel Jakub Dawidek <nick@garage.freebsd.pl>
This commit is contained in:
mux 2002-12-20 14:32:20 +00:00
parent c01cb9bac0
commit 516031bb16

View File

@ -103,6 +103,7 @@ jail(td, uap)
PROC_UNLOCK(p);
crfree(newcred);
bail:
mtx_destroy(&pr->pr_mtx);
FREE(pr, M_PRISON);
return (error);
}