diff options
author | Ulrich Weigand <uweigand@de.ibm.com> | 2009-07-02 17:02:35 +0000 |
---|---|---|
committer | Ulrich Weigand <uweigand@de.ibm.com> | 2009-07-02 17:02:35 +0000 |
commit | e17c207e88cbd63e9dc9dce1f3458a8ced4ff566 (patch) | |
tree | 6e430d068a5c19b425cf75b9c809b445a0e25bd0 /gdb/reggroups.c | |
parent | 50810684816502312a09d6713844c7a63ffd97cc (diff) | |
download | binutils-gdb-e17c207e88cbd63e9dc9dce1f3458a8ced4ff566.tar.gz |
* arch-utils.c (selected_byte_order): Return target_byte_order_user.
(show_endian): Use target_byte_order_user if specified; otherwise
use get_current_arch () instead of current_gdbarch.
(show_architecture): Use set_architecture_string if specified;
otherwise use get_current_arch () instead of current_gdbarch.
(get_current_arch): New function.
* arch-utils.h (get_current_arch): Add prototype.
* osabi.c (show_osabi): Use get_current_arch () instead of
current_gdbarch.
* findcmd.c: Include "arch-utils.h".
(parse_find_args): Add BIG_P argument. Use it instead of byte order
of current_gdbarch.
(find_command): Use get_current_arch () instead of current_gdbarch.
Pass byte order to parse_find_args.
* maint.c: Include "arch-utils.h".
(maintenance_print_architecture): Use get_current_arch () instead
of current_gdbarch.
* reggroups.c: Include "arch-utils.h".
(maintenance_print_reggroups): Use get_current_arch () instead
of current_gdbarch.
* symfile.c: Include "arch-utils.h".
(overlay_load_command): Use get_current_arch () instead of
current_gdbarch.
* value.c: Include "arch-utils.h".
(show_convenience): Use get_current_arch () instead of
current_gdbarch.
* tui/tui-regs.c: Include "arch-utils.h".
(tui_reg_next_command): Use get_current_arch () instead of
current_gdbarch.
* mi/mi-main.c: Include "arch-utils.h".
(mi_cmd_data_read_memory): Use get_current_arch () instead of
current_gdbarch.
* parse.c: Include "arch-utils.h".
(parse_exp_in_context): Use get_current_arch () instead of
current_gdbarch.
Diffstat (limited to 'gdb/reggroups.c')
-rw-r--r-- | gdb/reggroups.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gdb/reggroups.c b/gdb/reggroups.c index 080342206cb..171fc366549 100644 --- a/gdb/reggroups.c +++ b/gdb/reggroups.c @@ -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); } } |