X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Finfcall.c;h=9e434a9df41e6b299456000a601097d835731cdf;hb=51abb421302bdd86946827727aebc878b5c756e3;hp=38335a799627c491826c41f3191cead06a223243;hpb=aa0061181ab00081e9907447561e589d6edee9f2;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/infcall.c b/gdb/infcall.c index 38335a7996..9e434a9df4 100644 --- a/gdb/infcall.c +++ b/gdb/infcall.c @@ -1051,17 +1051,16 @@ call_function_by_hand_dummy (struct value *function, inferior. That way it breaks when it returns. */ { - struct breakpoint *bpt, *longjmp_b; - struct symtab_and_line sal; - - init_sal (&sal); /* initialize to zeroes */ + symtab_and_line sal; sal.pspace = current_program_space; sal.pc = bp_addr; sal.section = find_pc_overlay (sal.pc); + /* Sanity. The exact same SP value is returned by PUSH_DUMMY_CALL, saved as the dummy-frame TOS, and used by dummy_id to form the frame ID's stack address. */ - bpt = set_momentary_breakpoint (gdbarch, sal, dummy_id, bp_call_dummy); + breakpoint *bpt = set_momentary_breakpoint (gdbarch, sal, + dummy_id, bp_call_dummy); /* set_momentary_breakpoint invalidates FRAME. */ frame = NULL; @@ -1069,7 +1068,7 @@ call_function_by_hand_dummy (struct value *function, bpt->disposition = disp_del; gdb_assert (bpt->related_breakpoint == bpt); - longjmp_b = set_longjmp_breakpoint_for_call_dummy (); + breakpoint *longjmp_b = set_longjmp_breakpoint_for_call_dummy (); if (longjmp_b) { /* Link BPT into the chain of LONGJMP_B. */