This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: bug in elf32-tic6x.c binutils


On Thu, 1 Mar 2012, Eliot Dresselhaus wrote:

> Without the patch "ld --warn-once -o /dev/null -b binary /dev/null" segfaults
> on binutils-2.22
> 
> diff --git a/bfd/elf32-tic6x.c b/bfd/elf32-tic6x.c
> index 19287fe..44042eb 100644
> --- a/bfd/elf32-tic6x.c
> +++ b/bfd/elf32-tic6x.c
> @@ -4018,6 +4018,9 @@ elf32_tic6x_merge_private_bfd_data (bfd *ibfd, bfd
> *obfd)
>    if (!_bfd_generic_verify_endian_match (ibfd, obfd))
>      return FALSE;
> 
> +  if (! is_tic6x_elf (ibfd) || ! is_tic6x_elf (obfd))
> +    return TRUE;
> +

Thanks, I've committed this patch.

We really ought to have an architecture-independent test for this in the 
ld testsuite, I'm pretty sure I've seen such issues for other 
architectures before....

-- 
Joseph S. Myers
joseph@codesourcery.com


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