aboutsummaryrefslogtreecommitdiff
path: root/gdb/break-catch-sig.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2022-01-02 11:46:15 -0700
committerTom Tromey <tom@tromey.com>2022-03-29 12:46:24 -0600
commit6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a (patch)
tree641a6a86240919fe4ba9219fbbbe15bc6331c22d /gdb/break-catch-sig.c
parenta11ac3b3e8ff6769badcf0041894f6c5acc1b94f (diff)
downloadgdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.zip
gdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.tar.gz
gdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.tar.bz2
Unify gdb printf functions
Now that filtered and unfiltered output can be treated identically, we can unify the printf family of functions. This is done under the name "gdb_printf". Most of this patch was written by script.
Diffstat (limited to 'gdb/break-catch-sig.c')
-rw-r--r--gdb/break-catch-sig.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/gdb/break-catch-sig.c b/gdb/break-catch-sig.c
index b41a908..b739ca7 100644
--- a/gdb/break-catch-sig.c
+++ b/gdb/break-catch-sig.c
@@ -193,7 +193,7 @@ signal_catchpoint_print_it (bpstat *bs)
annotate_catchpoint (b->number);
maybe_print_thread_hit_breakpoint (uiout);
- printf_filtered (_("Catchpoint %d (signal %s), "), b->number, signal_name);
+ gdb_printf (_("Catchpoint %d (signal %s), "), b->number, signal_name);
return PRINT_SRC_AND_LOC;
}
@@ -261,22 +261,22 @@ signal_catchpoint_print_mention (struct breakpoint *b)
if (!c->signals_to_be_caught.empty ())
{
if (c->signals_to_be_caught.size () > 1)
- printf_filtered (_("Catchpoint %d (signals"), b->number);
+ gdb_printf (_("Catchpoint %d (signals"), b->number);
else
- printf_filtered (_("Catchpoint %d (signal"), b->number);
+ gdb_printf (_("Catchpoint %d (signal"), b->number);
for (gdb_signal iter : c->signals_to_be_caught)
{
const char *name = signal_to_name_or_int (iter);
- printf_filtered (" %s", name);
+ gdb_printf (" %s", name);
}
- printf_filtered (")");
+ gdb_printf (")");
}
else if (c->catch_all)
- printf_filtered (_("Catchpoint %d (any signal)"), b->number);
+ gdb_printf (_("Catchpoint %d (any signal)"), b->number);
else
- printf_filtered (_("Catchpoint %d (standard signals)"), b->number);
+ gdb_printf (_("Catchpoint %d (standard signals)"), b->number);
}
/* Implement the "print_recreate" breakpoint_ops method for signal
@@ -287,15 +287,15 @@ signal_catchpoint_print_recreate (struct breakpoint *b, struct ui_file *fp)
{
struct signal_catchpoint *c = (struct signal_catchpoint *) b;
- fprintf_unfiltered (fp, "catch signal");
+ gdb_printf (fp, "catch signal");
if (!c->signals_to_be_caught.empty ())
{
for (gdb_signal iter : c->signals_to_be_caught)
- fprintf_unfiltered (fp, " %s", signal_to_name_or_int (iter));
+ gdb_printf (fp, " %s", signal_to_name_or_int (iter));
}
else if (c->catch_all)
- fprintf_unfiltered (fp, " all");
+ gdb_printf (fp, " all");
gdb_putc ('\n', fp);
}