This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] ia64-tdep.c: ia64_gdbarch_init() fix


I've just committed the change below.

	From Peter Schauer  <pes@regent.e-technik.tu-muenchen.de>:
	* ia64-tdep.c (ia64_gdbarch_init): Eliminate incorrect use
	of ``current_gdbarch''.

Index: ia64-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/ia64-tdep.c,v
retrieving revision 1.24
diff -u -p -r1.24 ia64-tdep.c
--- ia64-tdep.c	2001/10/21 17:19:37	1.24
+++ ia64-tdep.c	2002/02/18 05:43:49
@@ -2090,9 +2090,9 @@ ia64_gdbarch_init (struct gdbarch_info i
        arches != NULL;
        arches = gdbarch_list_lookup_by_info (arches->next, &info))
     {
-      if (gdbarch_tdep (current_gdbarch)->os_ident != os_ident)
-	continue;
-      return arches->gdbarch;
+      tdep = gdbarch_tdep (arches->gdbarch);
+      if (tdep &&tdep->os_ident == os_ident)
+	return arches->gdbarch;
     }
 
   tdep = xmalloc (sizeof (struct gdbarch_tdep));


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]