summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--debugger.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/debugger.c b/debugger.c
index a1ff940..b08faf6 100644
--- a/debugger.c
+++ b/debugger.c
@@ -87,15 +87,16 @@ static void uninstall_breakpoints(struct thread *th) {
if (b->installed) {
ptrace(PTRACE_POKETEXT, th->id, b->address, b->text);
b->installed = 0;
- }
- if (b->enabled < 0) {
- struct thread *t;
- if (b->tid == 0 ||
- ((t = thread_by_id(th->proc, b->tid)) && !t->shouldcont)) {
- struct breakpoint *del = b;
- b = b->next;
- list_remove(del);
- free(del);
+
+ if (b->enabled < 0) {
+ struct thread *t;
+ if (b->tid == 0 ||
+ ((t = thread_by_id(th->proc, b->tid)) && !t->doing)) {
+ struct breakpoint *del = b;
+ b = b->next;
+ list_remove(del);
+ free(del);
+ }
}
}
}