[binutils-gdb] bfd: fix STRICT_PE_FORMAT build
Jan Beulich
jbeulich@sourceware.org
Fri Apr 21 10:06:06 GMT 2023
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=ae272fb8a57bb03dcc8ff800bb1b861bdc79933f
commit ae272fb8a57bb03dcc8ff800bb1b861bdc79933f
Author: Jan Beulich <jbeulich@suse.com>
Date: Fri Apr 21 12:05:56 2023 +0200
bfd: fix STRICT_PE_FORMAT build
A semicolon was missing and "name" needs to be pointer-to-const. While
adding "const" there, also add it for "sec".
Diff:
---
bfd/coffcode.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 5d6be493325..423f6c070ef 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -5028,11 +5028,11 @@ coff_classify_symbol (bfd *abfd,
breaks gas generated objects. */
if (syment->n_value == 0)
{
- asection *sec;
- char * name;
+ const asection *sec;
+ const char *name;
char buf[SYMNMLEN + 1];
- name = _bfd_coff_internal_syment_name (abfd, syment, buf)
+ name = _bfd_coff_internal_syment_name (abfd, syment, buf);
sec = coff_section_from_bfd_index (abfd, syment->n_scnum);
if (sec != NULL && name != NULL
&& (strcmp (bfd_section_name (sec), name) == 0))
More information about the Binutils-cvs
mailing list