From f596b03f555fa4e473bd3fbeb0d7b6662883485b Mon Sep 17 00:00:00 2001 From: Jan Beulich Date: Tue, 23 Mar 2021 08:42:58 +0100 Subject: [PATCH] bfd: avoid "shadowing" of glibc function name Old enough glibc has an (unguarded) declaration of index() in string.h, which triggers a "shadows a global declaration" warning. --- bfd/ChangeLog | 4 ++++ bfd/dwarf2.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index c4172ebe5e3..3245f8c5ad3 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,7 @@ +2021-03-23 Jan Beulich + + * dwarf2.c (read_indexed_string): Rename index to idx. + 2021-03-22 Martin Liska * bfd-in.h (startswith): Add startswith function. diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c index 9f895b1a20a..dbaec4016c1 100644 --- a/bfd/dwarf2.c +++ b/bfd/dwarf2.c @@ -1172,7 +1172,7 @@ is_str_attr (enum dwarf_form form) } static const char * -read_indexed_string (bfd_uint64_t index ATTRIBUTE_UNUSED, +read_indexed_string (bfd_uint64_t idx ATTRIBUTE_UNUSED, struct comp_unit * unit ATTRIBUTE_UNUSED) { /* FIXME: Add support for indexed strings. */ -- 2.30.2