This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: possible inclusion of Jim's recent "p" packet fix in 6.3 branch?
- From: Andrew Cagney <cagney at gnu dot org>
- To: Paul Schlie <schlie at comcast dot net>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Fri, 05 Nov 2004 18:41:15 -0500
- Subject: Re: possible inclusion of Jim's recent "p" packet fix in 6.3 branch?
- References: <BDA646F1.7959%schlie@comcast.net>
Paul Schlie wrote:
Might it be possible to have Jim's "p packet formatting fix" patch:
http://sources.redhat.com/ml/gdb-patches/2004-10/msg00458.html
Also applied to the 6.3 branch in the near term, as it's fairly
critical for cross host platform interfacing?
(as well as any others recently approved that are viewed as
likely critical for inclusion as well, would be helpful?)
Done.
Andrew
2004-11-05 Andrew Cagney <cagney@gnu.org>
Backport 2004-10-27 Jim Blandy <jimb@redhat.com>
* remote.c (fetch_register_using_p): Construct 'p' packet in a
manner independent of the host byte order.
Index: remote.c
===================================================================
RCS file: /cvs/src/src/gdb/remote.c,v
retrieving revision 1.151
diff -p -u -r1.151 remote.c
--- remote.c 8 Oct 2004 20:29:54 -0000 1.151
+++ remote.c 5 Nov 2004 22:12:39 -0000
@@ -3176,9 +3176,10 @@ fetch_register_using_p (int regnum)
char regp[MAX_REGISTER_SIZE];
int i;
- buf[0] = 'p';
- bin2hex((char *) ®num, &buf[1], sizeof(regnum));
- buf[9] = 0;
+ p = buf;
+ *p++ = 'p';
+ p += hexnumstr (p, regnum);
+ *p++ = '\0';
remote_send (buf, rs->remote_packet_size);
if (buf[0] != 0 && buf[0] != 'E') {
p = buf;