* go32-nat.c (go32_stop): Delete.
(go32_kill_inferior): Rewrite to only call go32_mourn_inferior. (go32_create_inferior): Don't call go32_stop or go32_kill_inferior. (go32_mourn_inferior): Inline go32_stop and go32_kill_inferior here. (init_go32_ops): Don't register go32_stop.
This commit is contained in:
parent
d067a4028a
commit
67ce33d768
|
@ -1,3 +1,13 @@
|
||||||
|
2009-05-04 Pedro Alves <pedro@codesourcery.com>
|
||||||
|
|
||||||
|
* go32-nat.c (go32_stop): Delete.
|
||||||
|
(go32_kill_inferior): Rewrite to only call go32_mourn_inferior.
|
||||||
|
(go32_create_inferior): Don't call go32_stop or
|
||||||
|
go32_kill_inferior.
|
||||||
|
(go32_mourn_inferior): Inline go32_stop and go32_kill_inferior
|
||||||
|
here.
|
||||||
|
(init_go32_ops): Don't register go32_stop.
|
||||||
|
|
||||||
2009-05-02 Eli Zaretskii <eliz@gnu.org>
|
2009-05-02 Eli Zaretskii <eliz@gnu.org>
|
||||||
|
|
||||||
* dbxread.c (read_dbx_symtab): Avoid compiler warnings for
|
* dbxread.c (read_dbx_symtab): Avoid compiler warnings for
|
||||||
|
|
|
@ -249,7 +249,6 @@ static int go32_xfer_memory (CORE_ADDR memaddr, gdb_byte *myaddr, int len,
|
||||||
struct mem_attrib *attrib,
|
struct mem_attrib *attrib,
|
||||||
struct target_ops *target);
|
struct target_ops *target);
|
||||||
static void go32_files_info (struct target_ops *target);
|
static void go32_files_info (struct target_ops *target);
|
||||||
static void go32_stop (ptid_t);
|
|
||||||
static void go32_kill_inferior (struct target_ops *ops);
|
static void go32_kill_inferior (struct target_ops *ops);
|
||||||
static void go32_create_inferior (struct target_ops *ops, char *exec_file,
|
static void go32_create_inferior (struct target_ops *ops, char *exec_file,
|
||||||
char *args, char **env, int from_tty);
|
char *args, char **env, int from_tty);
|
||||||
|
@ -634,26 +633,10 @@ go32_files_info (struct target_ops *target)
|
||||||
printf_unfiltered ("You are running a DJGPP V2 program.\n");
|
printf_unfiltered ("You are running a DJGPP V2 program.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
go32_stop (ptid_t ptid)
|
|
||||||
{
|
|
||||||
normal_stop ();
|
|
||||||
cleanup_client ();
|
|
||||||
ptid = inferior_ptid;
|
|
||||||
inferior_ptid = null_ptid;
|
|
||||||
delete_thread_silent (ptid);
|
|
||||||
prog_has_started = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
go32_kill_inferior (struct target_ops *ops)
|
go32_kill_inferior (struct target_ops *ops)
|
||||||
{
|
{
|
||||||
redir_cmdline_delete (&child_cmd);
|
go32_mourn_inferior (ops);
|
||||||
resume_signal = -1;
|
|
||||||
resume_is_step = 0;
|
|
||||||
if (!ptid_equal (inferior_ptid, null_ptid))
|
|
||||||
delete_thread_silent (inferior_ptid);
|
|
||||||
unpush_target (&go32_ops);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -671,11 +654,6 @@ go32_create_inferior (struct target_ops *ops, char *exec_file,
|
||||||
if (exec_file == 0)
|
if (exec_file == 0)
|
||||||
exec_file = get_exec_file (1);
|
exec_file = get_exec_file (1);
|
||||||
|
|
||||||
if (prog_has_started)
|
|
||||||
{
|
|
||||||
go32_stop (inferior_ptid);
|
|
||||||
go32_kill_inferior (ops);
|
|
||||||
}
|
|
||||||
resume_signal = -1;
|
resume_signal = -1;
|
||||||
resume_is_step = 0;
|
resume_is_step = 0;
|
||||||
|
|
||||||
|
@ -749,6 +727,14 @@ go32_create_inferior (struct target_ops *ops, char *exec_file,
|
||||||
static void
|
static void
|
||||||
go32_mourn_inferior (struct target_ops *ops)
|
go32_mourn_inferior (struct target_ops *ops)
|
||||||
{
|
{
|
||||||
|
ptid_t ptid;
|
||||||
|
|
||||||
|
redir_cmdline_delete (&child_cmd);
|
||||||
|
resume_signal = -1;
|
||||||
|
resume_is_step = 0;
|
||||||
|
|
||||||
|
cleanup_client ();
|
||||||
|
|
||||||
/* We need to make sure all the breakpoint enable bits in the DR7
|
/* We need to make sure all the breakpoint enable bits in the DR7
|
||||||
register are reset when the inferior exits. Otherwise, if they
|
register are reset when the inferior exits. Otherwise, if they
|
||||||
rerun the inferior, the uncleared bits may cause random SIGTRAPs,
|
rerun the inferior, the uncleared bits may cause random SIGTRAPs,
|
||||||
|
@ -757,7 +743,13 @@ go32_mourn_inferior (struct target_ops *ops)
|
||||||
at all times, but it doesn't, probably under an assumption that
|
at all times, but it doesn't, probably under an assumption that
|
||||||
the OS cleans up when the debuggee exits. */
|
the OS cleans up when the debuggee exits. */
|
||||||
i386_cleanup_dregs ();
|
i386_cleanup_dregs ();
|
||||||
go32_kill_inferior (ops);
|
|
||||||
|
ptid = inferior_ptid;
|
||||||
|
inferior_ptid = null_ptid;
|
||||||
|
delete_thread_silent (ptid);
|
||||||
|
prog_has_started = 0;
|
||||||
|
|
||||||
|
unpush_target (ops);
|
||||||
generic_mourn_inferior ();
|
generic_mourn_inferior ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -972,7 +964,6 @@ init_go32_ops (void)
|
||||||
go32_ops.to_create_inferior = go32_create_inferior;
|
go32_ops.to_create_inferior = go32_create_inferior;
|
||||||
go32_ops.to_mourn_inferior = go32_mourn_inferior;
|
go32_ops.to_mourn_inferior = go32_mourn_inferior;
|
||||||
go32_ops.to_can_run = go32_can_run;
|
go32_ops.to_can_run = go32_can_run;
|
||||||
go32_ops.to_stop = go32_stop;
|
|
||||||
go32_ops.to_thread_alive = go32_thread_alive;
|
go32_ops.to_thread_alive = go32_thread_alive;
|
||||||
go32_ops.to_pid_to_str = go32_pid_to_str;
|
go32_ops.to_pid_to_str = go32_pid_to_str;
|
||||||
go32_ops.to_stratum = process_stratum;
|
go32_ops.to_stratum = process_stratum;
|
||||||
|
|
Loading…
Reference in New Issue