diff options
author | Vladimir Prus <vladimir@codesourcery.com> | 2008-04-24 11:13:44 +0000 |
---|---|---|
committer | Vladimir Prus <vladimir@codesourcery.com> | 2008-04-24 11:13:44 +0000 |
commit | f107f56344531e3fa4cc74cac1fe7dd7b056edab (patch) | |
tree | eed53c115858c881d21a5dc2e16d415b47764870 /gdb/infrun.c | |
parent | 74960c600257a48df8589c16b527ab6f56d1a664 (diff) | |
download | gdb-f107f56344531e3fa4cc74cac1fe7dd7b056edab.zip gdb-f107f56344531e3fa4cc74cac1fe7dd7b056edab.tar.gz gdb-f107f56344531e3fa4cc74cac1fe7dd7b056edab.tar.bz2 |
exec_cleanup murder.
* breakpoint.c (until_break_command_continuation): Add
the 'error' parameter. Directly delete the breakoint as
opposed to running cleanups.
(until_break_command): Install continuation only
after starting the target. Don't use exec cleanups,
use ordinary cleanups. Discard cleanups is successfully
started the target in async mode.
(make_cleanup_delete_breakpoint): Remove.
* breakpoint.h (make_cleanup_delete_breakpoint): Remove
declaration.
* defs.h (do_exec_cleanups, make_exec_cleanup): Remove
declarations.
(struct continations): Add the 'error' parameter to the
continuation_hook field.
(add_continuation, do_all_continuations)
(add_intermediate_continuation)
(do_all_intermediate_continuations): Add the 'error' parameter.
* exceptions.c (throw_exception): Don't call do_exec_cleanups.
* inf-loop.c (inferior_event_handler): Instead of calling
discard_all_continuations, use do_all_continuations with 1 as
'error' parameter. Pass 0 as 'error' parameter in existing uses
of discard_all_continuations.
* infcmd.c (step_1): Do not use exec cleanup. For async case, discard
cleanups.
(step_once): Install continuation only after resuming the target.
(step_1_continuation): Disable longjmp breakpoint on error.
(finish_command_continuation): Add the error parameter. Delete
the finish breakpoint directly, do not use cleanups.
(finish_command): Do not use exec_cleanups. Always setup
continuation. For sync case, immediately run them.
(attach_command_continuation): Add the error parameter.
* infrun.c (fetch_inferior_event): Do not use exec cleanups to
remove step_resume_breakpoint -- adjust delete it directly.
* interps.c (interp_set): Adjust call to do_all_continations.
* mi/mi-interp.c (mi_interpreter_exec_continuation): Do not
do exec cleanups.
* mi/mi-main.c (mi_cmd_target_select): Do not do exec
cleanups.
(mi_cmd_execute): Do not use exec_cleanup.
(mi_execute_async_cli_command): Simplify the string concatenation
logic. Do no use exec cleanup.
(mi_exec_async_cli_cmd_continuation): New parameter error.
Free last_async_command.
* top.c (command_line_handler_continuation): New parameter error.
* utils.c (exec_cleanup_chain, make_exec_cleanup)
(do_exec_cleanups): Remove.
(add_continuation, do_all_continations)
(add_intermediate_continuation)
(do_all_intermediate_continuations): New parameter error.
Diffstat (limited to 'gdb/infrun.c')
-rw-r--r-- | gdb/infrun.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/gdb/infrun.c b/gdb/infrun.c index da8c3e0..e47cf1e 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -1073,9 +1073,6 @@ fetch_inferior_event (void *client_data) if (!async_ecs->wait_some_more) { - old_cleanups = make_exec_cleanup (delete_step_resume_breakpoint, - &step_resume_breakpoint); - /* Fill in with reasonable starting values. */ init_execution_control_state (async_ecs); @@ -1104,10 +1101,8 @@ fetch_inferior_event (void *client_data) if (!async_ecs->wait_some_more) { - /* Do only the cleanups that have been added by this - function. Let the continuations for the commands do the rest, - if there are any. */ - do_exec_cleanups (old_cleanups); + delete_step_resume_breakpoint (&step_resume_breakpoint); + normal_stop (); if (step_multi && stop_step) inferior_event_handler (INF_EXEC_CONTINUE, NULL); |