Flush the register windows before we start changing the context.
Submitted by: Andrew Belashov <bel (at) orel.ru> (slightly modified) Reviewed by: jake
This commit is contained in:
parent
38ce00cc1c
commit
22149b5972
@ -646,6 +646,8 @@ set_mcontext(struct thread *td, const mcontext_t *mc)
|
||||
return (EINVAL);
|
||||
tf = td->td_frame;
|
||||
pcb = td->td_pcb;
|
||||
/* Make sure the windows are spilled first. */
|
||||
flushw();
|
||||
wstate = tf->tf_wstate;
|
||||
bcopy(mc, tf, sizeof(*tf));
|
||||
tf->tf_wstate = wstate;
|
||||
|
Loading…
Reference in New Issue
Block a user