aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote.c
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2006-10-18 16:56:13 +0000
committerDaniel Jacobowitz <drow@false.org>2006-10-18 16:56:13 +0000
commit8621d6a94413b84d5d3353b717607194d7584943 (patch)
tree3f3e64904b3db0afa9355cc3e57e752b715b1526 /gdb/remote.c
parent2f83a18e2abe9144bfbb72bc75a68ba64445a9e1 (diff)
downloadgdb-8621d6a94413b84d5d3353b717607194d7584943.zip
gdb-8621d6a94413b84d5d3353b717607194d7584943.tar.gz
gdb-8621d6a94413b84d5d3353b717607194d7584943.tar.bz2
* inferior.h (start_remote): Update prototype.
* infrun.c (start_remote): Take FROM_TTY. Call post_create_inferior. * monitor.c (monitor_open): Update call to start_remote. * remote-sds.c (sds_start_remote, sds_open): Likewise. * remote.c (remote_start_remote): Likewise. (remote_start_remote_dummy): Removed. (remote_open): Update call to remote_start_remote. Do not call post_create_inferior here.
Diffstat (limited to 'gdb/remote.c')
-rw-r--r--gdb/remote.c22
1 files changed, 7 insertions, 15 deletions
diff --git a/gdb/remote.c b/gdb/remote.c
index cf872b1..98fe59d 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -1987,20 +1987,13 @@ get_offsets (void)
objfile_relocate (symfile_objfile, offs);
}
-/* Stub for catch_errors. */
-
-static int
-remote_start_remote_dummy (struct ui_out *uiout, void *dummy)
-{
- start_remote (); /* Initialize gdb process mechanisms. */
- /* NOTE: Return something >=0. A -ve value is reserved for
- catch_exceptions. */
- return 1;
-}
+/* Stub for catch_exception. */
static void
-remote_start_remote (struct ui_out *uiout, void *dummy)
+remote_start_remote (struct ui_out *uiout, void *from_tty_p)
{
+ int from_tty = * (int *) from_tty_p;
+
immediate_quit++; /* Allow user to interrupt it. */
/* Ack any packet which the remote side has already sent. */
@@ -2016,7 +2009,7 @@ remote_start_remote (struct ui_out *uiout, void *dummy)
putpkt ("?"); /* Initiate a query from remote machine. */
immediate_quit--;
- remote_start_remote_dummy (uiout, dummy);
+ start_remote (from_tty); /* Initialize gdb process mechanisms. */
}
/* Open a connection to a remote debugger.
@@ -2458,7 +2451,8 @@ remote_open_1 (char *name, int from_tty, struct target_ops *target,
function. See cli-dump.c. */
{
struct gdb_exception ex
- = catch_exception (uiout, remote_start_remote, NULL, RETURN_MASK_ALL);
+ = catch_exception (uiout, remote_start_remote, &from_tty,
+ RETURN_MASK_ALL);
if (ex.reason < 0)
{
pop_target ();
@@ -2478,8 +2472,6 @@ remote_open_1 (char *name, int from_tty, struct target_ops *target,
getpkt (&rs->buf, &rs->buf_size, 0);
}
- post_create_inferior (&current_target, from_tty);
-
if (exec_bfd) /* No use without an exec file. */
remote_check_symbols (symfile_objfile);
}