aboutsummaryrefslogtreecommitdiff
path: root/gdb/top.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@adacore.com>2022-08-11 10:07:18 -0600
committerTom Tromey <tromey@adacore.com>2022-08-31 11:03:39 -0600
commit992aeed80b0a6ef1d60ce01df52f3397c3274f35 (patch)
tree1a7af982504b79000f29ccf44ef52e739b7e1a97 /gdb/top.c
parent55a6603404099c0b61a5e4613712d3935c2e2bb6 (diff)
downloadgdb-992aeed80b0a6ef1d60ce01df52f3397c3274f35.zip
gdb-992aeed80b0a6ef1d60ce01df52f3397c3274f35.tar.gz
gdb-992aeed80b0a6ef1d60ce01df52f3397c3274f35.tar.bz2
Use ui_out_redirect_pop in more places
This changes ui_out_redirect_pop to also perform the redirection, and then updates several sites to use this, rather than explicit redirects.
Diffstat (limited to 'gdb/top.c')
-rw-r--r--gdb/top.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gdb/top.c b/gdb/top.c
index 18a447e..d8e0ee5 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -735,8 +735,7 @@ execute_fn_to_ui_file (struct ui_file *file, std::function<void(void)> fn)
scoped_restore save_async = make_scoped_restore (&current_ui->async, 0);
{
- current_uiout->redirect (file);
- ui_out_redirect_pop redirect_popper (current_uiout);
+ ui_out_redirect_pop redirect_popper (current_uiout, file);
scoped_restore save_stdout
= make_scoped_restore (&gdb_stdout, file);