2012-07-24 Jan Waclawek <konfera@efton.sk>

PR 13899
	* elf32-avr.c (elf32_avr_relax_delete_bytes): Call
	_bfd_elf_link_read_relocs with keep_memory as TRUE.
This commit is contained in:
Eric B. Weddington 2012-07-24 21:44:44 +00:00
parent 9b8d1a3603
commit 6aa82b649b
2 changed files with 6 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2012-07-24 Jan Waclawek <konfera@efton.sk>
PR 13899
* elf32-avr.c (elf32_avr_relax_delete_bytes): Call
_bfd_elf_link_read_relocs with keep_memory as TRUE.
2012-07-24 Teresa Johnson <tejohnson@google.com>
* bfd.c (bfd_find_nearest_line_discriminator): New macro.

View File

@ -1558,7 +1558,7 @@ elf32_avr_relax_delete_bytes (bfd *abfd,
irel = elf_section_data (isec)->relocs;
/* PR 12161: Read in the relocs for this section if necessary. */
if (irel == NULL)
irel = _bfd_elf_link_read_relocs (abfd, isec, NULL, NULL, FALSE);
irel = _bfd_elf_link_read_relocs (abfd, isec, NULL, NULL, TRUE);
for (irelend = irel + isec->reloc_count;
irel < irelend;
@ -1617,9 +1617,6 @@ elf32_avr_relax_delete_bytes (bfd *abfd,
/* else...Reference symbol is extern. No need for adjusting
the addend. */
}
if (elf_section_data (isec)->relocs == NULL)
free (irelend - isec->reloc_count);
}
}