aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/infcmd.c4
-rw-r--r--gdb/mi/mi-main.c7
2 files changed, 8 insertions, 3 deletions
diff --git a/gdb/infcmd.c b/gdb/infcmd.c
index 2c60be3..6bbd456 100644
--- a/gdb/infcmd.c
+++ b/gdb/infcmd.c
@@ -603,6 +603,8 @@ continue_1 (int all_threads)
/* Backup current thread and selected frame and restore on scope
exit. */
scoped_restore_current_thread restore_thread;
+ scoped_disable_commit_resumed disable_commit_resumed
+ ("continue all threads in non-stop");
iterate_over_threads (proceed_thread_callback, NULL);
@@ -623,6 +625,8 @@ continue_1 (int all_threads)
*/
target_terminal::inferior ();
}
+
+ disable_commit_resumed.reset_and_commit ();
}
else
{
diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c
index 44008d1..e28fae0 100644
--- a/gdb/mi/mi-main.c
+++ b/gdb/mi/mi-main.c
@@ -266,7 +266,6 @@ exec_continue (char **argv, int argc)
{
prepare_execution_command (current_inferior ()->top_target (), mi_async_p ());
- scoped_disable_commit_resumed disable_commit_resumed ("mi continue");
if (non_stop)
{
@@ -279,6 +278,8 @@ exec_continue (char **argv, int argc)
if (current_context->all || current_context->thread_group != -1)
{
scoped_restore_current_thread restore_thread;
+ scoped_disable_commit_resumed disable_commit_resumed
+ ("MI continue all threads in non-stop");
int pid = 0;
if (!current_context->all)
@@ -288,7 +289,9 @@ exec_continue (char **argv, int argc)
pid = inf->pid;
}
+
iterate_over_threads (proceed_thread_callback, &pid);
+ disable_commit_resumed.reset_and_commit ();
}
else
{
@@ -313,8 +316,6 @@ exec_continue (char **argv, int argc)
continue_1 (1);
}
}
-
- disable_commit_resumed.reset_and_commit ();
}
static void