* [RFA] Fix {get|put}_frame_register_bytes
@ 2007-01-13 17:31 Mark Kettenis
2007-01-13 18:26 ` Ulrich Weigand
0 siblings, 1 reply; 2+ messages in thread
From: Mark Kettenis @ 2007-01-13 17:31 UTC (permalink / raw)
To: uweigand; +Cc: gdb-patches
Hi Ulrich,
Looks like there's a bug in the new get_frame_register_bytes() and
put_frame_register_bytes(). I suppose the patch below is what you
intended.
Caught on OpenBSD/powerpc.
ok?
Mark
Index: ChangeLog
from Mark Kettenis <kettenis@gnu.org>
* frame.c (get_frame_register_bytes, put_frame_register_bytes):
Don't forget to move destination pointer.
Index: frame.c
===================================================================
RCS file: /cvs/src/src/gdb/frame.c,v
retrieving revision 1.219
diff -u -p -r1.219 frame.c
--- frame.c 11 Jan 2007 17:18:22 -0000 1.219
+++ frame.c 13 Jan 2007 17:28:47 -0000
@@ -775,6 +775,7 @@ get_frame_register_bytes (struct frame_i
memcpy (myaddr, buf + offset, curr_len);
}
+ myaddr += curr_len;
len -= curr_len;
offset = 0;
regnum++;
@@ -815,6 +816,7 @@ put_frame_register_bytes (struct frame_i
put_frame_register (frame, regnum, buf);
}
+ myaddr += curr_len;
len -= curr_len;
offset = 0;
regnum++;
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-01-13 18:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-13 17:31 [RFA] Fix {get|put}_frame_register_bytes Mark Kettenis
2007-01-13 18:26 ` Ulrich Weigand
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox