Fix bug introduced when multiarching NUM_REGS.
authorKevin Buettner <kevinb@redhat.com>
Sat, 21 Dec 2002 06:36:02 +0000 (06:36 +0000)
committerKevin Buettner <kevinb@redhat.com>
Sat, 21 Dec 2002 06:36:02 +0000 (06:36 +0000)
gdb/ChangeLog
gdb/mips-tdep.c

index caf57c3d1350fe8fc7e9fada7aa334bf2dc50720..f0ce860e0e459d835ec8496667ff8e9b2375c10c 100644 (file)
@@ -1,3 +1,9 @@
+2002-12-20  Kevin Buettner  <kevinb@redhat.com>
+
+       * mips-tdep.c (heuristic_proc_desc): Clear memory associated with
+       ``temp_saved_regs'', not the pointer or other storage contiguous
+       to this pointer.
+
 2002-12-20  Kevin Buettner  <kevinb@redhat.com>
 
        * Makefile.in (mips-linux-tdep.o): Add $(osabi_h) and $(gdb_string_h).
index 4fbaaf8e8a91f53da7e9a3400b87e39d09d443f7..1686ee45433705fb5626be87862cc341e8a7c1e1 100644 (file)
@@ -2142,7 +2142,7 @@ heuristic_proc_desc (CORE_ADDR start_pc, CORE_ADDR limit_pc,
     return NULL;
   memset (&temp_proc_desc, '\0', sizeof (temp_proc_desc));
   temp_saved_regs = xrealloc (temp_saved_regs, SIZEOF_FRAME_SAVED_REGS);
-  memset (&temp_saved_regs, '\0', SIZEOF_FRAME_SAVED_REGS);
+  memset (temp_saved_regs, '\0', SIZEOF_FRAME_SAVED_REGS);
   PROC_LOW_ADDR (&temp_proc_desc) = start_pc;
   PROC_FRAME_REG (&temp_proc_desc) = SP_REGNUM;
   PROC_PC_REG (&temp_proc_desc) = RA_REGNUM;