get_frame_saved_regs broken

Andreas Schwab schwab@issan.informatik.uni-dortmund.de
Mon Dec 28 01:53:00 GMT 1998


This patch fixes an obvious bug in get_frame_saved_regs.


1998-12-27  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>

	* blockframe.c (get_frame_saved_regs): Pass address of local
	saved_regs instead of saved_regs_addr to memcpy if the latter is
	NULL.

--- gdb-19981215/gdb/blockframe.c.~1~	Fri Dec 18 20:33:08 1998
+++ gdb-19981215/gdb/blockframe.c	Sun Dec 27 14:06:43 1998
@@ -539,7 +539,7 @@
     {
       struct frame_saved_regs saved_regs;
       FRAME_FIND_SAVED_REGS (frame, saved_regs);
-      memcpy (frame->saved_regs, saved_regs_addr, SIZEOF_FRAME_SAVED_REGS);
+      memcpy (frame->saved_regs, &saved_regs, SIZEOF_FRAME_SAVED_REGS);
     }
   else
     {

-- 
Andreas Schwab                                      "And now for something
schwab@issan.cs.uni-dortmund.de                      completely different"
schwab@gnu.org



More information about the Gdb-patches mailing list