This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: bfd/elf.c : bfd_seek to 0 valid ?
- From: jeroen dobbelaere <jeroen dot dobbelaere at acunia dot com>
- To: Richard dot Earnshaw at arm dot com
- Cc: binutils at sources dot redhat dot com
- Date: Thu, 07 Nov 2002 16:11:17 +0100
- Subject: Re: bfd/elf.c : bfd_seek to 0 valid ?
- Organization: ACUNIA
- References: <200211071457.gA7EvfQ31077@pc960.cambridge.arm.com>
Richard Earnshaw wrote:
[..]
Well, since pos is calculated to be hdr->sh_offset + offset, and since it
seams reasonable for offset to be zero, the question has to be (assuming
offset can't be negative!) is it legitimate for hdr->sh_offset to zero.
My guess is that the answer to that question should normally be 'no', and
the reason for it being so is that the section hasn't been mapped into the
output bfd.
R.
section->name = '.rel.dyn' (output section); the content itself comes from a '.rel.got'.
I have the impression, that for some reason, the .rel.dyn section does not
get a fileposition assigned (resulting in the hdr->sh_offset == 0).
Where should this mapping to the output bfd happen ?
Greetings,
--
Jeroen Dobbelaere
Embedded Software Engineer
ACUNIA Embedded Solutions
http://www.acunia.com/aes