[RFA] Fix compilation warnings in irix-core.c
Eric Christopher
echristo@redhat.com
Tue Mar 29 06:03:00 GMT 2005
On Mon, 2005-03-28 at 14:44 -0800, Joel Brobecker wrote:
> Hello,
>
> GDB currently fails to build on mips/irix due to warnings now being
> turned into errors. I am unfortunately lacking the time to look deeply
> into this at the moment (I have asked one of my coworkers to help me
> with that), but there was one file where the fixes were I think obvious.
> Here is a patch for it:
>
> 2005-03-28 Joel Brobecker <brobecker@adacore.com>
>
> * irix-core.c (do_sections): Add parenthesis in expression
> to avoid a compiler warning.
> (irix_core_core_file_matches_executable_p): Add ATTRIBUTE_UNUSED
> to unused parameters to avoid a compiler warning.
if (!make_bfd_asection (abfd, secname,
- SEC_ALLOC | SEC_LOAD+SEC_HAS_CONTENTS,
+ SEC_ALLOC | (SEC_LOAD+SEC_HAS_CONTENTS),
Spaces around the + please.
irix_core_core_file_matches_executable_p (core_bfd, exec_bfd)
- bfd *core_bfd, *exec_bfd;
+ bfd *core_bfd ATTRIBUTE_UNUSED, *exec_bfd ATTRIBUTE_UNUSED;
Can you move this to:
bfd *core_bfd ATTRIBUTE_UNUSED;
bfd *exec_bfd ATTRIBUTE_UNUSED;
please?
OK with those changes. Though if you want to migrate the whole file to
ISO I'd appreciate it. For style just look at, say, elfxx-mips.c :)
-eric
More information about the Binutils
mailing list