Index: gdb/infrun.c =================================================================== --- gdb.orig/infrun.c 2009-01-22 14:58:31.000000000 +0800 +++ gdb/infrun.c 2009-01-22 16:26:46.000000000 +0800 @@ -3488,10 +3488,21 @@ keep_going (ecs); return; } - /* Normal (staticly linked) function call return. */ - init_sal (&sr_sal); - sr_sal.pc = ecs->stop_func_start; - insert_step_resume_breakpoint_at_sal (sr_sal, null_frame_id); + if (ecs->stop_func_start != stop_pc) + { + /* Normal (staticly linked) function call return. */ + init_sal (&sr_sal); + sr_sal.pc = ecs->stop_func_start; + insert_step_resume_breakpoint_at_sal (sr_sal, null_frame_id); + } + else + { + /* We are stepping over a function call in reverse, and + stop at the start address of the function. Go back to + single-stepping, which should take us back to the + function call. */ + ecs->event_thread->stepping_over_breakpoint = 1; + } } else insert_step_resume_breakpoint_at_caller (get_current_frame ());