This is the mail archive of the elfutils-devel@sourceware.org mailing list for the elfutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] libdwfl: Never relocate value against section zero (load address).


On Sun, 2014-12-07 at 23:45 +0100, Mark Wielaard wrote:
> This really is just a robustify patch in case section zero got the
> wrong section flags set. In that case __libdwfl_relocate_value might
> call dwfl_offline_section_address which might assert (because it isn't
> prepared to handle section zero). elf_nextscn will never see section zero.
> So be explicit in dwfl_offline_section_address and immediately assert
> when shndx is zero. And handle section zero immediately by not relocating
> the value in __libdwfl_relocate_value.
>
> +2014-12-07  Mark Wielaard  <mjw@redhat.com>
> +
> +	* offline.c (dwfl_offline_section_address): Assert shndx is not zero.
> +	* relocate.c (__libdwfl_relocate_value): Don't relocate against
> +	section zero.

I pushed this to master now.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]