Revert: solib_global_lookup: Fetch arch from objfile.
authorUlrich Weigand <ulrich.weigand@de.ibm.com>
Fri, 28 Aug 2015 17:04:56 +0000 (19:04 +0200)
committerUlrich Weigand <ulrich.weigand@de.ibm.com>
Fri, 28 Aug 2015 17:04:56 +0000 (19:04 +0200)
solib_ops are installed as a property of the inferior gdbarch,
so they need to be systematically looked up via that architecture,
not some objfile architecture.

ChangeLog:

Revert:
2014-11-06  Doug Evans  <xdje42@gmail.com>
        * solib.c (solib_global_lookup): Fetch arch from objfile,
        not target_gdbarch.

gdb/ChangeLog
gdb/solib.c

index 21c7b42..2b1fad9 100644 (file)
@@ -1,3 +1,10 @@
+2015-08-28  Ulrich Weigand  <uweigand@de.ibm.com>
+
+       Revert:
+       2014-11-06  Doug Evans  <xdje42@gmail.com>
+       * solib.c (solib_global_lookup): Fetch arch from objfile,
+       not target_gdbarch.
+
 2015-08-27  Ulrich Weigand  <uweigand@de.ibm.com>
 
        * ppc-linux-tdep.c (ppc_linux_spe_context_lookup): Do not
index d2ea901..c46116d 100644 (file)
@@ -1516,7 +1516,7 @@ solib_global_lookup (struct objfile *objfile,
                     const char *name,
                     const domain_enum domain)
 {
-  const struct target_so_ops *ops = solib_ops (get_objfile_arch (objfile));
+  const struct target_so_ops *ops = solib_ops (target_gdbarch ());
 
   if (ops->lookup_lib_global_symbol != NULL)
     return ops->lookup_lib_global_symbol (objfile, name, domain);