Revert the last change.
[deliverable/binutils-gdb.git] / gdb / reggroups.c
index a4e1d3178c87d07d948be6fe6b2f95be029a8c0e..171fc36654990954fe67d861c68bc33ebe8517bb 100644 (file)
@@ -1,6 +1,6 @@
 /* Register groupings for GDB, the GNU debugger.
 
-   Copyright (C) 2002, 2003, 2007, 2008 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2003, 2007, 2008, 2009 Free Software Foundation, Inc.
 
    Contributed by Red Hat.
 
@@ -20,6 +20,7 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
+#include "arch-utils.h"
 #include "reggroups.h"
 #include "gdbtypes.h"
 #include "gdb_assert.h"
@@ -230,8 +231,10 @@ reggroups_dump (struct gdbarch *gdbarch, struct ui_file *file)
 static void
 maintenance_print_reggroups (char *args, int from_tty)
 {
+  struct gdbarch *gdbarch = get_current_arch ();
+
   if (args == NULL)
-    reggroups_dump (current_gdbarch, gdb_stdout);
+    reggroups_dump (gdbarch, gdb_stdout);
   else
     {
       struct cleanup *cleanups;
@@ -239,7 +242,7 @@ maintenance_print_reggroups (char *args, int from_tty)
       if (file == NULL)
        perror_with_name (_("maintenance print reggroups"));
       cleanups = make_cleanup_ui_file_delete (file);
-      reggroups_dump (current_gdbarch, file);    
+      reggroups_dump (gdbarch, file);
       do_cleanups (cleanups);
     }
 }
This page took 0.024242 seconds and 4 git commands to generate.