[PATCH/committed] sim: mn10300: fix sim_engine_halt call
Checks
Commit Message
The sim_stop argument is an enum and should only be one of those
values, not a signal constant. Fix the logic to pass the right
sim_xxx & SIM_xxx values in the right arguments.
---
sim/mn10300/op_utils.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
@@ -155,7 +155,8 @@ do_syscall (SIM_DESC sd)
{
/* EXIT - caller can look in parm1 to work out the reason */
sim_engine_halt (simulator, STATE_CPU (simulator, 0), NULL, PC,
- (parm1 == 0xdead ? SIM_SIGABRT : sim_exited), parm1);
+ parm1 == 0xdead ? sim_stopped : sim_exited,
+ parm1 == 0xdead ? SIM_SIGABRT : parm1);
}
else
{