To avoid sleeping with all sorts of resources acquired (the reported
problem was a locked directory vnode), do not give the process a chance to sleep in state "stopevent" (depends on the S_EXEC bit being set in p_stops) until most resources have been released again. Approved by: re
This commit is contained in:
parent
db2661ce96
commit
d1989db545
@ -567,8 +567,6 @@ interpret:
|
||||
* If tracing the process, trap to debugger so breakpoints
|
||||
* can be set before the program executes.
|
||||
*/
|
||||
_STOPEVENT(p, S_EXEC, 0);
|
||||
|
||||
if (p->p_flag & P_TRACED)
|
||||
psignal(p, SIGTRAP);
|
||||
|
||||
@ -640,8 +638,14 @@ exec_fail_dealloc:
|
||||
if (imgp->object)
|
||||
vm_object_deallocate(imgp->object);
|
||||
|
||||
if (error == 0)
|
||||
if (error == 0) {
|
||||
/*
|
||||
* Stop the process here if its stop event mask has
|
||||
* the S_EXEC bit set.
|
||||
*/
|
||||
STOPEVENT(p, S_EXEC, 0);
|
||||
goto done2;
|
||||
}
|
||||
|
||||
exec_fail:
|
||||
/* we're done here, clear P_INEXEC */
|
||||
|
Loading…
x
Reference in New Issue
Block a user