*** empty log message ***
[deliverable/binutils-gdb.git] / gdb / solib-legacy.c
index 2e32e187f0ad47dc906e8ce7e4cecdf7baa9da2f..2dd9fa5fd023843b58755c021de405b0ac2aaa4b 100644 (file)
@@ -19,7 +19,6 @@
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-#define _SYSCALL32     /* for Sparc64 cross Sparc32 */
 #include "defs.h"
 #include "gdbcore.h"
 #include "solib-svr4.h"
@@ -130,11 +129,15 @@ legacy_svr4_fetch_link_map_offsets (void)
 #endif /* defined (HAVE_STRUCT_LINK_MAP32) */
 
 #if defined (HAVE_STRUCT_LINK_MAP32)
-  if (bfd_get_arch_size (exec_bfd) == 32)
+  if (exec_bfd != NULL)
+    {
+      if (bfd_get_arch_size (exec_bfd) == 32)
+       return lmp32;
+    }
+  if (TARGET_PTR_BIT == 32)
     return lmp32;
-  else
 #endif
-    return lmp;
+  return lmp;
 }
 
 #endif /* HAVE_LINK_H */
This page took 0.023256 seconds and 4 git commands to generate.