block, but credentials should be alive until the process is really
dead. from tegge@idt.unit.no; netbsd pr#1767
*/
(void)chgproccnt(p->p_cred->p_ruid, -1);
+ /*
+ * Release reference to text vnode
+ */
+ if (p->p_textvp)
+ vrele(p->p_textvp);
+
/*
* Free up credentials.
*/
FREE(p->p_cred, M_SUBPROC);
}
- /*
- * Release reference to text vnode
- */
- if (p->p_textvp)
- vrele(p->p_textvp);
-
/*
* Finally finished with old proc entry.
* Unlink it from its process group and free it.