Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Kevin Buettner <kevinb@redhat.com>
To: gdb-patches@sources.redhat.com
Subject: [PATCH] mips-tdep.c: Fix bug introduced at time of NUM_REGS multiarch
Date: Fri, 20 Dec 2002 22:46:00 -0000	[thread overview]
Message-ID: <1021221063923.ZM27492@localhost.localdomain> (raw)

I've just committed the patch below.  As noted in the subject, it fixes
a bug that was introduced when I multiarched NUM_REGS a short time ago.

	* mips-tdep.c (heuristic_proc_desc): Clear memory associated with
	``temp_saved_regs'', not the pointer or other storage contiguous
	to this pointer.

Index: mips-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/mips-tdep.c,v
retrieving revision 1.147
diff -u -p -r1.147 mips-tdep.c
--- mips-tdep.c	13 Dec 2002 18:09:30 -0000	1.147
+++ mips-tdep.c	21 Dec 2002 06:31:58 -0000
@@ -2142,7 +2142,7 @@ heuristic_proc_desc (CORE_ADDR start_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;


             reply	other threads:[~2002-12-21  6:39 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-20 22:46 Kevin Buettner [this message]
2003-01-06 14:24 ` Andrew Cagney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1021221063923.ZM27492@localhost.localdomain \
    --to=kevinb@redhat.com \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox