From: fche@cygnus.com (Frank Ch. Eigler)
To: stcarrez@worldnet.fr (Stephane Carrez)
Cc: gdb-patches@cygnus.com
Subject: Re: Correction of a crash in sim_memory_uninstall
Date: Wed, 14 Apr 1999 13:22:00 -0000 [thread overview]
Message-ID: <o5vhezugrm.fsf@toenail.to.cygnus.com> (raw)
Message-ID: <19990414132200.i1lNAqaA0tlmYfWuOcwrC5ox1y_UItQWE68lwQFHb7o@z> (raw)
In-Reply-To: <37066006.ACFDED96.cygnus.patches.gdb@worldnet.fr>
stcarrez@worldnet.fr (Stephane Carrez) writes:
> I've found a problem in the common part of the simulator. It
> crashes in `sim_memory_uninstall' when the simulator terminates.
> [...]
Thanks for finding this problem. Your patch looks fine.
- FChE
From jimb@cygnus.com Thu Apr 15 11:41:00 1999
From: Jim Blandy <jimb@cygnus.com>
To: Manfred Hollstein <manfred.h@gmx.net>
Cc: bug-gdb@gnu.org, gdb-patches@cygnus.com
Subject: Re: PATCH: fix unitialized memory reads in bfd/elf32-mips.c
Date: Thu, 15 Apr 1999 11:41:00 -0000
Message-id: <npiuaxyf3t.fsf@zwingli.cygnus.com>
References: <14034.52083.787129.934623@exept.exept.de> <14100.46517.331398.118164@saturn.hollstein.net>
X-SW-Source: 1999-04/msg00033.html
Content-length: 2716
> I reported this problem already with bfd in binutils-2.9.1 and gdb-4.17;
> as it is still present in gdb-4.18, I'm re-posting a patch.
An equivalent patch has been applied now. Thanks!
------- Start of forwarded message -------
Message-ID: <19990414143605.B28302@cygnus.com>
Date: Wed, 14 Apr 1999 14:36:05 -0700
From: Richard Henderson <rth@cygnus.com>
To: Jim Blandy <jimb@cygnus.com>
Subject: Re: [manfred-h@t-online.de (Manfred Hollstein)] PATCH: fix unitialized memory reads in bfd/elf32-mips.c
References: <npbtgryt9k.fsf@zwingli.cygnus.com>
On Wed, Apr 14, 1999 at 01:03:03PM -0500, Jim Blandy wrote:
> 1999-04-14 Manfred Hollstein <mhollstein@cygnus.com>
>
> * elf32-mips.c (_bfd_mips_elf_read_ecoff_info): Set all
> fields to 0 which may cause erroneous calls to free when
> "goto error_return" is executed.
>
> + debug->line = 0;
> + debug->external_dnr = 0;
> + debug->external_pdr = 0;
> + debug->external_sym = 0;
> + debug->external_opt = 0;
> + debug->external_aux = 0;
> + debug->ss = 0;
> + debug->ssext = 0;
> + debug->external_fdr = 0;
> + debug->external_rfd = 0;
> + debug->external_ext = 0;
I've committed the following instead.
Thanks.
r~
Wed Apr 14 14:33:08 1999 Richard Henderson <rth@cygnus.com>
* elf32-mips.c (_bfd_mips_elf_read_ecoff_info): Zero `debug'.
* elf64-alpha.c (elf64_alpha_read_ecoff_info): Likewise.
Index: elf32-mips.c
===================================================================
RCS file: /cvs/cvsfiles/devo/bfd/elf32-mips.c,v
retrieving revision 1.153
diff -c -p -d -r1.153 elf32-mips.c
*** elf32-mips.c 1999/04/10 23:24:04 1.153
--- elf32-mips.c 1999/04/14 21:32:49
*************** _bfd_mips_elf_read_ecoff_info (abfd, sec
*** 3330,3335 ****
--- 3330,3336 ----
char *ext_hdr = NULL;
swap = get_elf_backend_data (abfd)->elf_backend_ecoff_debug_swap;
+ memset (debug, 0, sizeof(*debug));
ext_hdr = (char *) bfd_malloc ((size_t) swap->external_hdr_size);
if (ext_hdr == NULL && swap->external_hdr_size != 0)
Index: elf64-alpha.c
===================================================================
RCS file: /cvs/cvsfiles/devo/bfd/elf64-alpha.c,v
retrieving revision 1.43
diff -c -p -d -r1.43 elf64-alpha.c
*** elf64-alpha.c 1999/04/10 23:24:04 1.43
--- elf64-alpha.c 1999/04/14 21:32:49
*************** elf64_alpha_read_ecoff_info (abfd, secti
*** 1950,1955 ****
--- 1950,1956 ----
char *ext_hdr = NULL;
swap = get_elf_backend_data (abfd)->elf_backend_ecoff_debug_swap;
+ memset (debug, 0, sizeof(*debug));
ext_hdr = (char *) bfd_malloc ((size_t) swap->external_hdr_size);
if (ext_hdr == NULL && swap->external_hdr_size != 0)
------- End of forwarded message -------
next parent reply other threads:[~1999-04-14 13:22 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <37066006.ACFDED96.cygnus.patches.gdb@worldnet.fr>
1999-04-14 12:46 ` Frank Ch. Eigler [this message]
1999-04-14 13:22 ` Frank Ch. Eigler
1999-04-03 11:37 Stephane Carrez
1999-04-03 12:27 ` Stephane Carrez
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=o5vhezugrm.fsf@toenail.to.cygnus.com \
--to=fche@cygnus.com \
--cc=gdb-patches@cygnus.com \
--cc=stcarrez@worldnet.fr \
/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