[binutils-gdb] Stop the plugin handler from ignoring unknown symbol types when conanicalizing weak definitions.

Nick Clifton nickc@sourceware.org
Tue Sep 8 08:50:28 GMT 2020


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=b5ffa9182b5cfa038c494e4199224a90955d635d

commit b5ffa9182b5cfa038c494e4199224a90955d635d
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 8 09:49:15 2020 +0100

    Stop the plugin handler from ignoring unknown symbol types when conanicalizing weak definitions.
    
            * plugin.c (bfd_plugin_canonicalize_symtab): Handle the case of an
            unrecognized symbol type in a weak definition.

Diff:
---
 bfd/ChangeLog | 5 +++++
 bfd/plugin.c  | 2 ++
 2 files changed, 7 insertions(+)

diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 75bcf553162..22cee1d6642 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,8 @@
+2020-09-08  Nick Clifton  <nickc@redhat.com>
+
+	* plugin.c (bfd_plugin_canonicalize_symtab): Handle the case of an
+	unrecognized symbol type in a weak definition.
+
 2020-09-04  Alan Modra  <amodra@gmail.com>
 
 	PR 26574
diff --git a/bfd/plugin.c b/bfd/plugin.c
index 593e277747a..bed98520da0 100644
--- a/bfd/plugin.c
+++ b/bfd/plugin.c
@@ -640,6 +640,8 @@ bfd_plugin_canonicalize_symtab (bfd *abfd,
 	  if (current_plugin->has_symbol_type)
 	    switch (syms[i].symbol_type)
 	      {
+	      default:
+		/* FIXME: Should we issue an error here ?  */
 	      case LDST_UNKNOWN:
 		/* What is the best fake section for LDST_UNKNOWN?  */
 	      case LDST_FUNCTION:


More information about the Binutils-cvs mailing list