aboutsummaryrefslogtreecommitdiff
path: root/gdb/infcmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/infcmd.c')
-rw-r--r--gdb/infcmd.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/gdb/infcmd.c b/gdb/infcmd.c
index 4f55c33..06e3bc5 100644
--- a/gdb/infcmd.c
+++ b/gdb/infcmd.c
@@ -2245,6 +2245,15 @@ interrupt_target_1 (int all_threads)
else
ptid = inferior_ptid;
target_stop (ptid);
+
+ /* Tag the thread as having been explicitly requested to stop, so
+ other parts of gdb know not to resume this thread automatically,
+ if it was stopped due to an internal event. Limit this to
+ non-stop mode, as when debugging a multi-threaded application in
+ all-stop mode, we will only get one stop event --- it's undefined
+ which thread will report the event. */
+ if (non_stop)
+ set_stop_requested (ptid, 1);
}
/* Stop the execution of the target while running in async mode, in