From 397ca115344837d62d02f33e0bd6ac94a921336a Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 18 Jun 2005 11:39:36 +0000 Subject: [PATCH] (Server): Clarify that `file' should be used before connecting to the server. (Files): Add an xref to the above description. --- gdb/doc/ChangeLog | 6 ++++++ gdb/doc/gdb.texinfo | 15 ++++++++++----- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index 06ddd729629..7f4d1591650 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,9 @@ +2005-06-18 Eli Zaretskii + + * gdb.texinfo (Server): Clarify that `file' should be used before + connecting to the server. + (Files): Add an xref to the above description. + 2005-06-18 Nick Roberts * gdb.texinfo (GDB/MI Stack Manipulation): Remove reference to diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 2446da5947f..88b9a2676f1 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -10618,9 +10618,10 @@ way to do this is at start-up time, using the arguments to Out of @value{GDBN}}). Occasionally it is necessary to change to a different file during a -@value{GDBN} session. Or you may run @value{GDBN} and forget to specify -a file you want to use. In these situations the @value{GDBN} commands -to specify new files are useful. +@value{GDBN} session. Or you may run @value{GDBN} and forget to +specify a file you want to use. Or you are debugging a remote target +via @code{gdbserver} (@pxref{Server, file}). In these situations the +@value{GDBN} commands to specify new files are useful. @table @code @cindex executable file @@ -11941,8 +11942,12 @@ For TCP connections, you must start up @code{gdbserver} prior to using the @code{target remote} command. Otherwise you may get an error whose text depends on the host system, but which usually looks something like @samp{Connection refused}. You don't need to use the @code{load} -command in @value{GDBN} when using gdbserver, since the program is -already on the target. +command in @value{GDBN} when using @code{gdbserver}, since the program is +already on the target. However, if you want to load the symbols (as +you normally would), do that with the @code{file} command, and issue +it @emph{before} connecting to the server; otherwise, you will get an +error message saying @code{"Program is already running"}, since the +program is considered running after the connection. @end table -- 2.30.2