summaryrefslogtreecommitdiff
path: root/gdb/maint-test-options.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2021-12-30 12:16:58 -0700
committerTom Tromey <tom@tromey.com>2022-01-05 11:36:33 -0700
commit7befbbd4c3d50c17fb22d872fd933d8c917aa5ee (patch)
treed557613e147874cfadab23223b412fd571d6ddbc /gdb/maint-test-options.c
parent34fda50beed954b3fa392297c34c9417a81d7a38 (diff)
downloadbinutils-gdb-7befbbd4c3d50c17fb22d872fd933d8c917aa5ee.tar.gz
Use filtered output in some dumping commands
There are several commands that may optionally send their output to a file -- they take an optional filename argument and open a file. This patch changes these commands to use filtered output. The rationale here is that, when printing to gdb_stdout, filtering is appropriate -- it is, and should be, the default for all commands. And, when writing to a file, paging will not happen anyway (it only happens when the stream==gdb_stdout), so using the _filtered form will not change anything.
Diffstat (limited to 'gdb/maint-test-options.c')
-rw-r--r--gdb/maint-test-options.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/gdb/maint-test-options.c b/gdb/maint-test-options.c
index 87e810d8384..b9b538d78bb 100644
--- a/gdb/maint-test-options.c
+++ b/gdb/maint-test-options.c
@@ -143,22 +143,22 @@ struct test_options_opts
arguments. */
void dump (ui_file *file, const char *args) const
{
- fprintf_unfiltered (file,
- _("-flag %d -xx1 %d -xx2 %d -bool %d "
- "-enum %s -uint %s -zuint-unl %s -string '%s' -- %s\n"),
- flag_opt,
- xx1_opt,
- xx2_opt,
- boolean_opt,
- enum_opt,
- (uint_opt == UINT_MAX
- ? "unlimited"
- : pulongest (uint_opt)),
- (zuint_unl_opt == -1
- ? "unlimited"
- : plongest (zuint_unl_opt)),
- string_opt.c_str (),
- args);
+ fprintf_filtered (file,
+ _("-flag %d -xx1 %d -xx2 %d -bool %d "
+ "-enum %s -uint %s -zuint-unl %s -string '%s' -- %s\n"),
+ flag_opt,
+ xx1_opt,
+ xx2_opt,
+ boolean_opt,
+ enum_opt,
+ (uint_opt == UINT_MAX
+ ? "unlimited"
+ : pulongest (uint_opt)),
+ (zuint_unl_opt == -1
+ ? "unlimited"
+ : plongest (zuint_unl_opt)),
+ string_opt.c_str (),
+ args);
}
};