From 763b1b0909971ec7194f40b46463bc9e445f21e1 Mon Sep 17 00:00:00 2001 From: Michael Snyder Date: Sun, 16 May 2010 21:11:14 +0000 Subject: 2010-05-16 Michael Snyder * record.c: White space. * regcache.c: White space. * reggroups.c: White space. * remote-fileio.c: White space. * remote-m32r-sdi.c: White space. * remote-mips.c: White space. * remote-sim.c: White space. --- gdb/reggroups.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gdb/reggroups.c') diff --git a/gdb/reggroups.c b/gdb/reggroups.c index 01dbe34cd0f..fdc05754729 100644 --- a/gdb/reggroups.c +++ b/gdb/reggroups.c @@ -41,6 +41,7 @@ struct reggroup * reggroup_new (const char *name, enum reggroup_type type) { struct reggroup *group = XMALLOC (struct reggroup); + group->name = name; group->type = type; return group; @@ -81,6 +82,7 @@ reggroups_init (struct gdbarch *gdbarch) { struct reggroups *groups = GDBARCH_OBSTACK_ZALLOC (gdbarch, struct reggroups); + groups->last = &groups->first; return groups; } @@ -190,6 +192,7 @@ reggroups_dump (struct gdbarch *gdbarch, struct ui_file *file) /* Group name. */ { const char *name; + if (group == NULL) name = "Group"; else @@ -200,6 +203,7 @@ reggroups_dump (struct gdbarch *gdbarch, struct ui_file *file) /* Group type. */ { const char *type; + if (group == NULL) type = "Type"; else @@ -240,6 +244,7 @@ maintenance_print_reggroups (char *args, int from_tty) { struct cleanup *cleanups; struct ui_file *file = gdb_fopen (args, "w"); + if (file == NULL) perror_with_name (_("maintenance print reggroups")); cleanups = make_cleanup_ui_file_delete (file); -- cgit v1.2.1