From: Joel Brobecker <brobecker@gnat.com>
To: Kevin Buettner <kevinb@redhat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Fix a compilation failure in rs6000-nat.c
Date: Fri, 04 Jul 2003 16:49:00 -0000 [thread overview]
Message-ID: <20030704164910.GV945@gnat.com> (raw)
In-Reply-To: <1030702180245.ZM1441@localhost.localdomain>
[-- Attachment #1: Type: text/plain, Size: 952 bytes --]
Hi Kevin,
Sorry it took me so long to get back to you. Our AiX machine suffered
a severe breakdown, and had to be completely reinstalled :(.
> I don't think this is quite right. After looking at the other
> substitutions that were done along these lines[1], I think this should be:
>
> new_offsets = (struct section_offsets *)
> alloca (SIZEOF_N_SECTION_OFFSETS (objfile->num_sections));
>
> Feel free to adjust the formatting.
>
> If you agree that this is the correct fix, please apply this change
> to both the mainline and gdb 6.0 branch. (But please post an updated
> patch showing what you committed.)
Good catch!
Here is the patch I ended up committing, on mainline and branch.
That leaves only one more problem before GDB is able to build on
AiX again (xcoffread.c).
2003-07-04 Joel Brobecker <brobecker@gnat.com>
* rs6000-nat.c (vmap_symtab): Fix compilation error.
(note: I used gdb_indent's formatting)
--
Joel
[-- Attachment #2: rs6000-nat.c.diff --]
[-- Type: text/plain, Size: 722 bytes --]
Index: rs6000-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/rs6000-nat.c,v
retrieving revision 1.31
diff -u -p -r1.31 rs6000-nat.c
--- rs6000-nat.c 10 Jun 2003 20:34:09 -0000 1.31
+++ rs6000-nat.c 4 Jul 2003 16:33:53 -0000
@@ -664,7 +664,9 @@ vmap_symtab (struct vmap *vp)
/* If symbols are not yet loaded, offsets are not yet valid. */
return;
- new_offsets = (struct section_offsets *) alloca (SIZEOF_SECTION_OFFSETS);
+ new_offsets =
+ (struct section_offsets *)
+ alloca (SIZEOF_N_SECTION_OFFSETS (objfile->num_sections));
for (i = 0; i < objfile->num_sections; ++i)
new_offsets->offsets[i] = ANOFFSET (objfile->section_offsets, i);
prev parent reply other threads:[~2003-07-04 16:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-01 0:37 Joel Brobecker
2003-07-01 0:40 ` Joel Brobecker
2003-07-02 18:02 ` Kevin Buettner
2003-07-04 16:49 ` Joel Brobecker [this message]
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=20030704164910.GV945@gnat.com \
--to=brobecker@gnat.com \
--cc=gdb-patches@sources.redhat.com \
--cc=kevinb@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