Fix address violation parsing a corrupt ieee binary.

PR binutils/21581
	(ieee_archive_p): Use a static buffer to avoid compiler bugs.
This commit is contained in:
Nick Clifton 2017-06-15 13:08:47 +01:00
parent 63634bb4a1
commit 62b76e4b6e
2 changed files with 3 additions and 1 deletions

View File

@ -3,6 +3,8 @@
PR binutils/21582
* ieee.c (ieee_object_p): Use a static buffer to avoid compiler
bugs.
PR binutils/21581
(ieee_archive_p): Likewise.
2017-06-15 Nick Clifton <nickc@redhat.com>

View File

@ -1355,7 +1355,7 @@ ieee_archive_p (bfd *abfd)
{
char *library;
unsigned int i;
unsigned char buffer[512];
static unsigned char buffer[512];
file_ptr buffer_offset = 0;
ieee_ar_data_type *save = abfd->tdata.ieee_ar_data;
ieee_ar_data_type *ieee;