[Bug binutils/17597] NULL pointer dereference in opncls.c in bfd_get_debug_link_info().

2014-11-17 Thread oxffffaa at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17597

--- Comment #5 from arseniy krasnov oxaa at gmail dot com ---
(In reply to Nick Clifton from comment #4)
 Created attachment 7935 [details]
 Fix derefence by checking length of the section
 
 I have applied this patch to the master branch sources.  It should fix the
 problem for you.
 
 Cheers
   Nick

Hi, thank you! Now seems ok!

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/17592] x86-64 linker generates wrong PLT for large model

2014-11-17 Thread matz at suse dot de
https://sourceware.org/bugzilla/show_bug.cgi?id=17592

Michael Matz matz at suse dot de changed:

   What|Removed |Added

 CC||matz at suse dot de

--- Comment #1 from Michael Matz matz at suse dot de ---
Back in http://www.sourceware.org/ml/binutils/2006-03/msg00276.html
I suggested to place .plt after .text so that PLT and GOT are nearer
to each other.  In that case the large PLT layout would only need to
be used if there were more that 100 million PLT slots (and GOT entry).

Nevertheless, for full large model support you're right, the large PLT
layout needs to be implemented.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/17597] NULL pointer dereference in opncls.c in bfd_get_debug_link_info().

2014-11-17 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17597

--- Comment #6 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  8f66a6af276d17c0e386cd2409873f2e3e0b8a37 (commit)
   via  32a9d621c3c480aa093a089a36e36c35f68a4010 (commit)
  from  ff67f476b9907b9fddfbafff52caa4cce6a6f58c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8f66a6af276d17c0e386cd2409873f2e3e0b8a37

commit 8f66a6af276d17c0e386cd2409873f2e3e0b8a37
Merge: 32a9d62 ff67f47
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 17:04:16 2014 +

Merge branch 'binutils-2_25-branch' of
ssh://sourceware.org/git/binutils-gdb into binutils-2_25-branch

Conflicts:
gas/ChangeLog

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=32a9d621c3c480aa093a089a36e36c35f68a4010

commit 32a9d621c3c480aa093a089a36e36c35f68a4010
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 16:59:09 2014 +

Applies a series of patches for PR 17512 and 17533 which fix invalid memory
accesses.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17512
* config/obj-coff.c (coff_obj_symbol_new_hook): Set the is_sym
field.

2014-11-14  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (get_encoded_value): Add an 'end' parameter.  Change the
'data' parameter to a double pointer and return the updated value.
(decode_location_expression): Update call to get_encoded_value.
(frame_need_space): Handle the case where one or both of the
mallocs fails.
(read_cie): Initialise the cie pointer, even if the read fails.
(display_debug_frames): Warn if the calculated block_end is before
the start of the block.  Break the loop if the CIE could not be
read.  Update call to get_encoded_value.  Warn if the read CFA
expressions are too big.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17531
* readelf.c (process_version_sections): If the read of the version
def information fails, make sure that the external verdef data is
not used.
(get_dynamic_data): Do not attempt to allocate memory for more
dynamic data than there is in the file.  If the read fails, free
the allocated buffer.
(process_symbol_table): Do not print dynamic information if we
were unable to read the dynamic symbol table.
(print_gnu_note): Do not print the note if the descsz is too
small.

2014-11-12  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (read_and_display_attr_value): Check that we do not read
past end.
(display_debug_pubnames_worker): Add range checks.
(process_debug_info): Check for invalid pointer sizes.
(display_loc_list): Likewise.
(display_loc_list_dwo): Likewise.
(display_debug_ranges): Likewise.
(display_debug_aranges): Check for invalid address size.
(read_cie): Add range checks.  Replace call strchr with while loop.
* objdump.c (dump_dwarf): Replace abort with a warning message.
(print_section_stabs): Improve range checks.
* rdcoff.c (coff_get_slot): Use long for indx parameter type.
Add check for an excesively large index.
* rddbg.c (read_section_stabs_debugging_info): Zero terminate the
string table.  Avoid walking off the end of the stabs data.
* stabs.c (parse_stab_string): Add check for a NULL name.

2014-11-11  Nick Clifton  ni...@redhat.com

PR binutils/17531
* binutils/readelf.c (dynamic_nent): Change type to size_t.
(slurp_rela_relocs): Use size_t type for nrelas.
(slurp_rel_relocs): Likewise.
(get_program_headers): Improve out of memory error message.
(get_32bit_section_headers): Likewise.
(get_32bit_section_headers): Likewise.
(get_64bit_section_headers): Likewise.
(get_32bit_elf_symbols): Likewise.
(get_64bit_elf_symbols): Likewise.
(process_section_groups): Likewise.
(get_32bit_dynamic_section): Likewise.
(get_64bit_dynamic_section): Likewise.
(process_dynamic_section): Likewise.
(process_version_sections): Likewise.
(get_symbol_index_type): Likewise.
(process_mips_specific): Likewise.
(process_corefile_note_segment): Likewise.
(process_version_sections): Use size_t type for total.

[Bug binutils/17512] segfault in PE parser / _bfd_pei_swap_aouthdr_in

2014-11-17 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17512

--- Comment #95 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  8f66a6af276d17c0e386cd2409873f2e3e0b8a37 (commit)
   via  32a9d621c3c480aa093a089a36e36c35f68a4010 (commit)
  from  ff67f476b9907b9fddfbafff52caa4cce6a6f58c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8f66a6af276d17c0e386cd2409873f2e3e0b8a37

commit 8f66a6af276d17c0e386cd2409873f2e3e0b8a37
Merge: 32a9d62 ff67f47
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 17:04:16 2014 +

Merge branch 'binutils-2_25-branch' of
ssh://sourceware.org/git/binutils-gdb into binutils-2_25-branch

Conflicts:
gas/ChangeLog

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=32a9d621c3c480aa093a089a36e36c35f68a4010

commit 32a9d621c3c480aa093a089a36e36c35f68a4010
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 16:59:09 2014 +

Applies a series of patches for PR 17512 and 17533 which fix invalid memory
accesses.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17512
* config/obj-coff.c (coff_obj_symbol_new_hook): Set the is_sym
field.

2014-11-14  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (get_encoded_value): Add an 'end' parameter.  Change the
'data' parameter to a double pointer and return the updated value.
(decode_location_expression): Update call to get_encoded_value.
(frame_need_space): Handle the case where one or both of the
mallocs fails.
(read_cie): Initialise the cie pointer, even if the read fails.
(display_debug_frames): Warn if the calculated block_end is before
the start of the block.  Break the loop if the CIE could not be
read.  Update call to get_encoded_value.  Warn if the read CFA
expressions are too big.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17531
* readelf.c (process_version_sections): If the read of the version
def information fails, make sure that the external verdef data is
not used.
(get_dynamic_data): Do not attempt to allocate memory for more
dynamic data than there is in the file.  If the read fails, free
the allocated buffer.
(process_symbol_table): Do not print dynamic information if we
were unable to read the dynamic symbol table.
(print_gnu_note): Do not print the note if the descsz is too
small.

2014-11-12  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (read_and_display_attr_value): Check that we do not read
past end.
(display_debug_pubnames_worker): Add range checks.
(process_debug_info): Check for invalid pointer sizes.
(display_loc_list): Likewise.
(display_loc_list_dwo): Likewise.
(display_debug_ranges): Likewise.
(display_debug_aranges): Check for invalid address size.
(read_cie): Add range checks.  Replace call strchr with while loop.
* objdump.c (dump_dwarf): Replace abort with a warning message.
(print_section_stabs): Improve range checks.
* rdcoff.c (coff_get_slot): Use long for indx parameter type.
Add check for an excesively large index.
* rddbg.c (read_section_stabs_debugging_info): Zero terminate the
string table.  Avoid walking off the end of the stabs data.
* stabs.c (parse_stab_string): Add check for a NULL name.

2014-11-11  Nick Clifton  ni...@redhat.com

PR binutils/17531
* binutils/readelf.c (dynamic_nent): Change type to size_t.
(slurp_rela_relocs): Use size_t type for nrelas.
(slurp_rel_relocs): Likewise.
(get_program_headers): Improve out of memory error message.
(get_32bit_section_headers): Likewise.
(get_32bit_section_headers): Likewise.
(get_64bit_section_headers): Likewise.
(get_32bit_elf_symbols): Likewise.
(get_64bit_elf_symbols): Likewise.
(process_section_groups): Likewise.
(get_32bit_dynamic_section): Likewise.
(get_64bit_dynamic_section): Likewise.
(process_dynamic_section): Likewise.
(process_version_sections): Likewise.
(get_symbol_index_type): Likewise.
(process_mips_specific): Likewise.
(process_corefile_note_segment): Likewise.
(process_version_sections): Use size_t type for total.

[Bug binutils/17533] objdump/ar/... crash on malformed ar file

2014-11-17 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17533

--- Comment #13 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  8f66a6af276d17c0e386cd2409873f2e3e0b8a37 (commit)
   via  32a9d621c3c480aa093a089a36e36c35f68a4010 (commit)
  from  ff67f476b9907b9fddfbafff52caa4cce6a6f58c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8f66a6af276d17c0e386cd2409873f2e3e0b8a37

commit 8f66a6af276d17c0e386cd2409873f2e3e0b8a37
Merge: 32a9d62 ff67f47
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 17:04:16 2014 +

Merge branch 'binutils-2_25-branch' of
ssh://sourceware.org/git/binutils-gdb into binutils-2_25-branch

Conflicts:
gas/ChangeLog

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=32a9d621c3c480aa093a089a36e36c35f68a4010

commit 32a9d621c3c480aa093a089a36e36c35f68a4010
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 16:59:09 2014 +

Applies a series of patches for PR 17512 and 17533 which fix invalid memory
accesses.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17512
* config/obj-coff.c (coff_obj_symbol_new_hook): Set the is_sym
field.

2014-11-14  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (get_encoded_value): Add an 'end' parameter.  Change the
'data' parameter to a double pointer and return the updated value.
(decode_location_expression): Update call to get_encoded_value.
(frame_need_space): Handle the case where one or both of the
mallocs fails.
(read_cie): Initialise the cie pointer, even if the read fails.
(display_debug_frames): Warn if the calculated block_end is before
the start of the block.  Break the loop if the CIE could not be
read.  Update call to get_encoded_value.  Warn if the read CFA
expressions are too big.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17531
* readelf.c (process_version_sections): If the read of the version
def information fails, make sure that the external verdef data is
not used.
(get_dynamic_data): Do not attempt to allocate memory for more
dynamic data than there is in the file.  If the read fails, free
the allocated buffer.
(process_symbol_table): Do not print dynamic information if we
were unable to read the dynamic symbol table.
(print_gnu_note): Do not print the note if the descsz is too
small.

2014-11-12  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (read_and_display_attr_value): Check that we do not read
past end.
(display_debug_pubnames_worker): Add range checks.
(process_debug_info): Check for invalid pointer sizes.
(display_loc_list): Likewise.
(display_loc_list_dwo): Likewise.
(display_debug_ranges): Likewise.
(display_debug_aranges): Check for invalid address size.
(read_cie): Add range checks.  Replace call strchr with while loop.
* objdump.c (dump_dwarf): Replace abort with a warning message.
(print_section_stabs): Improve range checks.
* rdcoff.c (coff_get_slot): Use long for indx parameter type.
Add check for an excesively large index.
* rddbg.c (read_section_stabs_debugging_info): Zero terminate the
string table.  Avoid walking off the end of the stabs data.
* stabs.c (parse_stab_string): Add check for a NULL name.

2014-11-11  Nick Clifton  ni...@redhat.com

PR binutils/17531
* binutils/readelf.c (dynamic_nent): Change type to size_t.
(slurp_rela_relocs): Use size_t type for nrelas.
(slurp_rel_relocs): Likewise.
(get_program_headers): Improve out of memory error message.
(get_32bit_section_headers): Likewise.
(get_32bit_section_headers): Likewise.
(get_64bit_section_headers): Likewise.
(get_32bit_elf_symbols): Likewise.
(get_64bit_elf_symbols): Likewise.
(process_section_groups): Likewise.
(get_32bit_dynamic_section): Likewise.
(get_64bit_dynamic_section): Likewise.
(process_dynamic_section): Likewise.
(process_version_sections): Likewise.
(get_symbol_index_type): Likewise.
(process_mips_specific): Likewise.
(process_corefile_note_segment): Likewise.
(process_version_sections): Use size_t type for total.

[Bug binutils/17531] readelf -a crashes on fuzzed samples

2014-11-17 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17531

--- Comment #32 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  8f66a6af276d17c0e386cd2409873f2e3e0b8a37 (commit)
   via  32a9d621c3c480aa093a089a36e36c35f68a4010 (commit)
  from  ff67f476b9907b9fddfbafff52caa4cce6a6f58c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8f66a6af276d17c0e386cd2409873f2e3e0b8a37

commit 8f66a6af276d17c0e386cd2409873f2e3e0b8a37
Merge: 32a9d62 ff67f47
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 17:04:16 2014 +

Merge branch 'binutils-2_25-branch' of
ssh://sourceware.org/git/binutils-gdb into binutils-2_25-branch

Conflicts:
gas/ChangeLog

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=32a9d621c3c480aa093a089a36e36c35f68a4010

commit 32a9d621c3c480aa093a089a36e36c35f68a4010
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 16:59:09 2014 +

Applies a series of patches for PR 17512 and 17533 which fix invalid memory
accesses.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17512
* config/obj-coff.c (coff_obj_symbol_new_hook): Set the is_sym
field.

2014-11-14  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (get_encoded_value): Add an 'end' parameter.  Change the
'data' parameter to a double pointer and return the updated value.
(decode_location_expression): Update call to get_encoded_value.
(frame_need_space): Handle the case where one or both of the
mallocs fails.
(read_cie): Initialise the cie pointer, even if the read fails.
(display_debug_frames): Warn if the calculated block_end is before
the start of the block.  Break the loop if the CIE could not be
read.  Update call to get_encoded_value.  Warn if the read CFA
expressions are too big.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17531
* readelf.c (process_version_sections): If the read of the version
def information fails, make sure that the external verdef data is
not used.
(get_dynamic_data): Do not attempt to allocate memory for more
dynamic data than there is in the file.  If the read fails, free
the allocated buffer.
(process_symbol_table): Do not print dynamic information if we
were unable to read the dynamic symbol table.
(print_gnu_note): Do not print the note if the descsz is too
small.

2014-11-12  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (read_and_display_attr_value): Check that we do not read
past end.
(display_debug_pubnames_worker): Add range checks.
(process_debug_info): Check for invalid pointer sizes.
(display_loc_list): Likewise.
(display_loc_list_dwo): Likewise.
(display_debug_ranges): Likewise.
(display_debug_aranges): Check for invalid address size.
(read_cie): Add range checks.  Replace call strchr with while loop.
* objdump.c (dump_dwarf): Replace abort with a warning message.
(print_section_stabs): Improve range checks.
* rdcoff.c (coff_get_slot): Use long for indx parameter type.
Add check for an excesively large index.
* rddbg.c (read_section_stabs_debugging_info): Zero terminate the
string table.  Avoid walking off the end of the stabs data.
* stabs.c (parse_stab_string): Add check for a NULL name.

2014-11-11  Nick Clifton  ni...@redhat.com

PR binutils/17531
* binutils/readelf.c (dynamic_nent): Change type to size_t.
(slurp_rela_relocs): Use size_t type for nrelas.
(slurp_rel_relocs): Likewise.
(get_program_headers): Improve out of memory error message.
(get_32bit_section_headers): Likewise.
(get_32bit_section_headers): Likewise.
(get_64bit_section_headers): Likewise.
(get_32bit_elf_symbols): Likewise.
(get_64bit_elf_symbols): Likewise.
(process_section_groups): Likewise.
(get_32bit_dynamic_section): Likewise.
(get_64bit_dynamic_section): Likewise.
(process_dynamic_section): Likewise.
(process_version_sections): Likewise.
(get_symbol_index_type): Likewise.
(process_mips_specific): Likewise.
(process_corefile_note_segment): Likewise.
(process_version_sections): Use size_t type for total.

[Bug binutils/17552] strip/objcopy: directory traversal

2014-11-17 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17552

--- Comment #13 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  8f66a6af276d17c0e386cd2409873f2e3e0b8a37 (commit)
   via  32a9d621c3c480aa093a089a36e36c35f68a4010 (commit)
  from  ff67f476b9907b9fddfbafff52caa4cce6a6f58c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8f66a6af276d17c0e386cd2409873f2e3e0b8a37

commit 8f66a6af276d17c0e386cd2409873f2e3e0b8a37
Merge: 32a9d62 ff67f47
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 17:04:16 2014 +

Merge branch 'binutils-2_25-branch' of
ssh://sourceware.org/git/binutils-gdb into binutils-2_25-branch

Conflicts:
gas/ChangeLog

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=32a9d621c3c480aa093a089a36e36c35f68a4010

commit 32a9d621c3c480aa093a089a36e36c35f68a4010
Author: Nick Clifton ni...@redhat.com
Date:   Mon Nov 17 16:59:09 2014 +

Applies a series of patches for PR 17512 and 17533 which fix invalid memory
accesses.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17512
* config/obj-coff.c (coff_obj_symbol_new_hook): Set the is_sym
field.

2014-11-14  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (get_encoded_value): Add an 'end' parameter.  Change the
'data' parameter to a double pointer and return the updated value.
(decode_location_expression): Update call to get_encoded_value.
(frame_need_space): Handle the case where one or both of the
mallocs fails.
(read_cie): Initialise the cie pointer, even if the read fails.
(display_debug_frames): Warn if the calculated block_end is before
the start of the block.  Break the loop if the CIE could not be
read.  Update call to get_encoded_value.  Warn if the read CFA
expressions are too big.

2014-11-13  Nick Clifton  ni...@redhat.com

PR binutils/17531
* readelf.c (process_version_sections): If the read of the version
def information fails, make sure that the external verdef data is
not used.
(get_dynamic_data): Do not attempt to allocate memory for more
dynamic data than there is in the file.  If the read fails, free
the allocated buffer.
(process_symbol_table): Do not print dynamic information if we
were unable to read the dynamic symbol table.
(print_gnu_note): Do not print the note if the descsz is too
small.

2014-11-12  Nick Clifton  ni...@redhat.com

PR binutils/17512
* dwarf.c (read_and_display_attr_value): Check that we do not read
past end.
(display_debug_pubnames_worker): Add range checks.
(process_debug_info): Check for invalid pointer sizes.
(display_loc_list): Likewise.
(display_loc_list_dwo): Likewise.
(display_debug_ranges): Likewise.
(display_debug_aranges): Check for invalid address size.
(read_cie): Add range checks.  Replace call strchr with while loop.
* objdump.c (dump_dwarf): Replace abort with a warning message.
(print_section_stabs): Improve range checks.
* rdcoff.c (coff_get_slot): Use long for indx parameter type.
Add check for an excesively large index.
* rddbg.c (read_section_stabs_debugging_info): Zero terminate the
string table.  Avoid walking off the end of the stabs data.
* stabs.c (parse_stab_string): Add check for a NULL name.

2014-11-11  Nick Clifton  ni...@redhat.com

PR binutils/17531
* binutils/readelf.c (dynamic_nent): Change type to size_t.
(slurp_rela_relocs): Use size_t type for nrelas.
(slurp_rel_relocs): Likewise.
(get_program_headers): Improve out of memory error message.
(get_32bit_section_headers): Likewise.
(get_32bit_section_headers): Likewise.
(get_64bit_section_headers): Likewise.
(get_32bit_elf_symbols): Likewise.
(get_64bit_elf_symbols): Likewise.
(process_section_groups): Likewise.
(get_32bit_dynamic_section): Likewise.
(get_64bit_dynamic_section): Likewise.
(process_dynamic_section): Likewise.
(process_version_sections): Likewise.
(get_symbol_index_type): Likewise.
(process_mips_specific): Likewise.
(process_corefile_note_segment): Likewise.
(process_version_sections): Use size_t type for total.

[Bug binutils/17531] readelf -a crashes on fuzzed samples

2014-11-17 Thread espen at grindhaug dot org
https://sourceware.org/bugzilla/show_bug.cgi?id=17531

Espen Grindhaug espen at grindhaug dot org changed:

   What|Removed |Added

 CC||espen at grindhaug dot org

--- Comment #33 from Espen Grindhaug espen at grindhaug dot org ---
Created attachment 7945
  -- https://sourceware.org/bugzilla/attachment.cgi?id=7945action=edit
Binary that triggers assert in decode_tic6x_unwind_bytecode

This binary is triggering an assert in decode_tic6x_unwind_bytecode

readelf: readelf.c:7586: decode_tic6x_unwind_bytecode: Assertion `i  sizeof
(buf)' failed.

The issue was found using american fuzzy lop.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/17592] x86-64 linker generates wrong PLT for large model

2014-11-17 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17592

--- Comment #2 from H.J. Lu hjl.tools at gmail dot com ---
(In reply to Michael Matz from comment #1)
 Back in http://www.sourceware.org/ml/binutils/2006-03/msg00276.html
 I suggested to place .plt after .text so that PLT and GOT are nearer
 to each other.  In that case the large PLT layout would only need to
 be used if there were more that 100 million PLT slots (and GOT entry).
 

It is an interesting idea.  If we place .plt just after .text, there
may be readonly sections before .got, the distance between .plt and
.got.plt can still be big.  If we place .plt just before .got, the
text segment will have text, readonly data and followed by text. Do
we want to do that?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/17615] New: arm64: ld.bfd generates SHN_ABS instead of SHN_UNDEF

2014-11-17 Thread dimitry at google dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17615

Bug ID: 17615
   Summary: arm64: ld.bfd generates SHN_ABS instead of SHN_UNDEF
   Product: binutils
   Version: 2.24
Status: NEW
  Severity: normal
  Priority: P2
 Component: binutils
  Assignee: unassigned at sourceware dot org
  Reporter: dimitry at google dot com

when compiling iproute2 'ip' binary for arm64 ld.bfd produces following symbol
in .dynsym section

11:  4 OBJECT  GLOBAL DEFAULT  ABS
__iproute2_user_hz_internal

The corresponding relocation is:

00045f78  000b0401 R_AARCH64_GLOB_DAT 
__iproute2_user_hz_internal + 0

when I compile the same code for arm I see symbol:

11:  0 OBJECT  GLOBAL DEFAULT  UND __iproute2_user_hz_internal

and relocation:

00030fbc  0b15 R_ARM_GLOB_DAT   
__iproute2_user_hz_internal

I believe that arm64 build should also produce undefined symbol here.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/17590] Order of multiple defsym commands irrelevant

2014-11-17 Thread amodra at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17590

Alan Modra amodra at gmail dot com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||amodra at gmail dot com
 Resolution|--- |WONTFIX

--- Comment #2 from Alan Modra amodra at gmail dot com ---
What you're missing is that the linking process makes multiple passes over the
linker script, and --defsym is effectively a tiny addition to the linker
script.

On the first pass you will get _three = _one and _one = _two.  The next pass
sets _threee to the new value of _one, ie _two.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


Re: Duplicate FDEs in .eh_frame

2014-11-17 Thread Alan Modra
On Thu, Nov 13, 2014 at 08:21:02AM -0500, Rene Gollent wrote:
 Hi there,
 
 I was wondering, is there a known/intended case where gcc + binutils
 will produce .eh_frame sections with duplicate FDEs? I'm seeing this
 with gcc 4.8.3 + binutils 2.24 on Haiku, and thought I'd see if this
 is intentional before I try to come up with a reduced testcase on
 another platform, as I don't believe all of our patches have been
 upstreamed at this point. The FDEs in question have the exact same
 lowpc/highpc, CIE and call frame instructions, the only discernable
 difference is that they're located in completely different parts of
 the section.

The cases I've seen involved C++ and ld -r.  Binutils git master and
binutils-2_25-branch should have the problem fixed.

See https://sourceware.org/bugzilla/show_bug.cgi?id=17467#c2

-- 
Alan Modra
Australia Development Lab, IBM

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils