gold patch committed: Don't crash with -s -r

Ian Lance Taylor iant@google.com
Wed Jun 29 21:28:00 GMT 2011


I haven't been able to recreate PR 12695.  However, while looking at it
I did see a possible linker crash with the somewhat unlikely combination
of -s -r.  This patch fixes the problem, by not trying to get the
section index of the .symtab section if there is no such section.
Committed to mainline.

Ian


2011-06-29  Ian Lance Taylor  <iant@google.com>

	PR gold/12695
	* layout.cc (Layout::symtab_section_shndx): New function.
	* layout.h (class Layout): Declare symtab_section_shndx.
	* output.cc (Output_section::write_header): Call it.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: foo.patch
Type: text/x-diff
Size: 2070 bytes
Desc: patch
URL: <https://sourceware.org/pipermail/binutils/attachments/20110629/dd57b883/attachment.bin>


More information about the Binutils mailing list