Use parameter instead of current_gdbarch

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Use parameter instead of current_gdbarch

Andreas Schwab
Don't use the global current_gdbarch when it's already passed as
parameter.  Checked in as obvious.

Andreas.

2007-04-01  Andreas Schwab  <[hidden email]>

        * 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, [hidden email]
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."