mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-03-21 09:51:41 +00:00
[gamecode] Improve watchpoint handling a little
Mostly just update the old value if the condition didn't trigger.
This commit is contained in:
parent
753d183d82
commit
1d6843d7f0
1 changed files with 8 additions and 5 deletions
|
@ -1698,11 +1698,14 @@ op_call:
|
|||
default:
|
||||
PR_RunError (pr, "Bad opcode %i", st->op);
|
||||
}
|
||||
if (watch && watch->integer_var != old_val.integer_var
|
||||
&& (!pr->wp_conditional
|
||||
|| watch->integer_var == pr->wp_val.integer_var))
|
||||
PR_RunError (pr, "watchpoint hit: %d -> %d", old_val.integer_var,
|
||||
watch->integer_var);
|
||||
if (watch && watch->integer_var != old_val.integer_var) {
|
||||
if (!pr->wp_conditional
|
||||
|| watch->integer_var == pr->wp_val.integer_var) {
|
||||
PR_RunError (pr, "watchpoint hit: %d -> %d",
|
||||
old_val.integer_var, watch->integer_var);
|
||||
}
|
||||
old_val.integer_var = watch->integer_var;
|
||||
}
|
||||
}
|
||||
exit_program:
|
||||
pr->pr_argc = 0;
|
||||
|
|
Loading…
Reference in a new issue