This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Use parameter instead of current_gdbarch
- From: Andreas Schwab <schwab at suse dot de>
- To: gdb-patches at sourceware dot org
- Date: Sun, 01 Apr 2007 20:25:22 +0200
- Subject: Use parameter instead of current_gdbarch
Don't use the global current_gdbarch when it's already passed as
parameter. Checked in as obvious.
Andreas.
2007-04-01 Andreas Schwab <schwab@suse.de>
* rs6000-tdep.c (rs6000_convert_from_func_ptr_addr): Use parameter
gdbarch instead of current_gdbarch.
Index: gdb/rs6000-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/rs6000-tdep.c,v
retrieving revision 1.268
diff -u -a -p -a -u -p -r1.268 gdb/rs6000-tdep.c
--- gdb/rs6000-tdep.c 27 Mar 2007 19:04:37 -0000 1.268
+++ gdb/rs6000-tdep.c 1 Apr 2007 18:01:49 -0000
@@ -2390,7 +2390,7 @@ rs6000_convert_from_func_ptr_addr (struc
return addr;
/* ADDR is in the data space, so it's a special function pointer. */
- return read_memory_addr (addr, gdbarch_tdep (current_gdbarch)->wordsize);
+ return read_memory_addr (addr, gdbarch_tdep (gdbarch)->wordsize);
}
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."