aboutsummaryrefslogtreecommitdiff
path: root/gdb/dummy-frame.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2008-10-30 20:35:31 +0000
committerTom Tromey <tromey@redhat.com>2008-10-30 20:35:31 +0000
commit724b958c4168d40f59a35112c36ebf9e02c43d56 (patch)
treef2cd63b030da519b513a58be98a7c010e9464dcb /gdb/dummy-frame.c
parenta05016c09e47a026bdbf05d02101c4eb40ac52f5 (diff)
* cli/cli-logging.c (handle_redirections): Make a cleanup.
* reggroups.c (maintenance_print_reggroups): Make a cleanup. * regcache.c (regcache_print): Make a cleanup. * maint.c (maintenance_print_architecture): Make a cleanup. * dummy-frame.c (maintenance_print_dummy_frames): Make a cleanup.
Diffstat (limited to 'gdb/dummy-frame.c')
-rw-r--r--gdb/dummy-frame.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/dummy-frame.c b/gdb/dummy-frame.c
index a27de2e28f..9cc3da7391 100644
--- a/gdb/dummy-frame.c
+++ b/gdb/dummy-frame.c
@@ -265,11 +265,13 @@ maintenance_print_dummy_frames (char *args, int from_tty)
fprint_dummy_frames (gdb_stdout);
else
{
+ struct cleanup *cleanups;
struct ui_file *file = gdb_fopen (args, "w");
if (file == NULL)
perror_with_name (_("maintenance print dummy-frames"));
+ cleanups = make_cleanup_ui_file_delete (file);
fprint_dummy_frames (file);
- ui_file_delete (file);
+ do_cleanups (cleanups);
}
}