diff options
author | Markus Metzger <markus.t.metzger@intel.com> | 2018-02-01 14:31:18 +0100 |
---|---|---|
committer | Markus Metzger <markus.t.metzger@intel.com> | 2018-04-13 11:30:15 +0200 |
commit | b85310e1ec0419c4e1ca091cdd48f7597ebbefd3 (patch) | |
tree | f554d5e6e022afc2bec6b9650c4e170ecd3f9cba /gdb/record-btrace.c | |
parent | 1d509aa625f891e20b37b8cee4659771e87b1ba4 (diff) | |
download | binutils-gdb-b85310e1ec0419c4e1ca091cdd48f7597ebbefd3.tar.gz |
btrace: fix output of "set record btrace"
Instead of giving a message that "set record btrace" needs a sub-command,
GDB crashed. Fix it. A regression test comes with the next patch.
gdb/
* record-btrace.c (cmd_set_record_btrace): Print sub-commands.
Diffstat (limited to 'gdb/record-btrace.c')
-rw-r--r-- | gdb/record-btrace.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gdb/record-btrace.c b/gdb/record-btrace.c index 7264b8ed2b6..455e25456be 100644 --- a/gdb/record-btrace.c +++ b/gdb/record-btrace.c @@ -2958,7 +2958,10 @@ cmd_record_btrace_start (const char *args, int from_tty) static void cmd_set_record_btrace (const char *args, int from_tty) { - cmd_show_list (set_record_btrace_cmdlist, from_tty, ""); + printf_unfiltered (_("\"set record btrace\" must be followed " + "by an appropriate subcommand.\n")); + help_list (set_record_btrace_cmdlist, "set record btrace ", + all_commands, gdb_stdout); } /* The "show record btrace" command. */ |