This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] Fixes for a small number of compiler warnings
- From: Alan Modra <amodra at gmail dot com>
- To: Ed Schouten <ed at nuxi dot nl>
- Cc: binutils at sourceware dot org, "H.J. Lu" <hjl dot tools at gmail dot com>
- Date: Fri, 27 Mar 2015 10:37:15 +1030
- Subject: Re: [PATCH] Fixes for a small number of compiler warnings
- Authentication-results: sourceware.org; auth=none
- References: <CABh_MK=meHjQHZH9Cssu3xSgsrehcar0-COMZSJf0cHZTKxH4A at mail dot gmail dot com>
On Thu, Mar 26, 2015 at 05:13:21PM +0100, Ed Schouten wrote:
> + * config/tc-i386.c (cpu_flags_set): Remove unused function.
I'll leave this one to HJ.
> diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
> index 618e20a..ece2fb0 100644
> --- a/ld/emultempl/elf32.em
> +++ b/ld/emultempl/elf32.em
> @@ -1412,7 +1412,7 @@ gld${EMULATION_NAME}_before_allocation (void)
> asection *sinterp;
> bfd *abfd;
> struct elf_link_hash_entry *ehdr_start = NULL;
> - struct bfd_link_hash_entry ehdr_start_save = ehdr_start_save;
> + struct bfd_link_hash_entry ehdr_start_save;
>
> if (is_elf_hash_table (link_info.hash))
> {
This was last changed by commit f9c316c4, which says
Silence uninitialized warning on ehdr_start_save
Older GCC, like 4.1/4.2, will issue an uninitialized warning on
ehdr_start_save. This patch silences by using
struct bfd_link_hash_entry ehdr_start_save = ehdr_start_save;
Blah. A warning fix for an older gcc that causes a warning in a
newer compiler.
--
Alan Modra
Australia Development Lab, IBM