* infcall.c (run_inferior_call): Remove references to

suppress_stop_observer.
	* infcmd.c (suppress_stop_observer): Delete.
	(finish_command_continuation): Remove NOTE.  Don't clear
	suppress_stop_observer anymore.
	(finish_command_continuation_free_arg): Likewise.
	(finish_forward): Remove references to suppress_stop_observer.
	Call normal_stop observer if we haven't already.
	* inferior.h (suppress_stop_observer): Delete.
	* infrun.c (normal_stop): When deciding to suppress the
	normal_stop observer, check for proceed_to_finish instead of
	suppress_stop_observer.
This commit is contained in:
Pedro Alves
2009-03-22 17:57:11 +00:00
parent 065a2c74b5
commit 41d2bdb467
5 changed files with 42 additions and 28 deletions

View File

@ -4433,11 +4433,25 @@ Further execution is probably impossible.\n"));
done:
annotate_stopped ();
if (!suppress_stop_observer
&& !(target_has_execution
&& last.kind != TARGET_WAITKIND_SIGNALLED
&& last.kind != TARGET_WAITKIND_EXITED
&& inferior_thread ()->step_multi))
/* Suppress the stop observer if we're in the middle of:
- a step n (n > 1), as there still more steps to be done.
- a "finish" command, as the observer will be called in
finish_command_continuation, so it can include the inferior
function's return value.
- calling an inferior function, as we pretend we inferior didn't
run at all. The return value of the call is handled by the
expression evaluator, through call_function_by_hand. */
if (!target_has_execution
|| last.kind == TARGET_WAITKIND_SIGNALLED
|| last.kind == TARGET_WAITKIND_EXITED
|| (!inferior_thread ()->step_multi
&& !(inferior_thread ()->stop_bpstat
&& inferior_thread ()->proceed_to_finish)))
{
if (!ptid_equal (inferior_ptid, null_ptid))
observer_notify_normal_stop (inferior_thread ()->stop_bpstat,