diff options
author | Steven Rostedt (Google) <rostedt@goodmis.org> | 2023-06-01 07:50:53 -0400 |
---|---|---|
committer | Steven Rostedt (Google) <rostedt@goodmis.org> | 2023-06-02 04:44:42 -0400 |
commit | 9c9d5ed97fcd7e5d1308c4f589d01949c8a1b007 (patch) | |
tree | 9b62bacaa020b39cf721dbf3daa28a265128a48e | |
parent | 4b9213298599e91682129294cd317ec780785947 (diff) | |
download | trace-cmd-9c9d5ed97fcd7e5d1308c4f589d01949c8a1b007.tar.gz |
trace-cmd extract: Do not extract top level unless told to
The trace-cmd extract man pages explicitly states that if the '-B'
option is used, it will only extract the given instance and not touch
any other buffer instance including the top level, unless '-t' is given
(for the top level) or '-a' (for all instances). But currently it is
hard coded to extract the top level. Make extract only touch what it is
told according to the documentation.
Link: https://lore.kernel.org/linux-trace-devel/20230601075053.3fa7dd9b@rorschach.local.home
Reported-by: Douglas RAILLARD <douglas.raillard@arm.com>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=217340
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
-rw-r--r-- | tracecmd/trace-record.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tracecmd/trace-record.c b/tracecmd/trace-record.c index 32fbfef5..a692523a 100644 --- a/tracecmd/trace-record.c +++ b/tracecmd/trace-record.c @@ -7141,7 +7141,7 @@ void trace_extract(int argc, char **argv) type = get_trace_cmd_type(ctx.curr_cmd); - update_first_instance(ctx.instance, 1); + update_first_instance(ctx.instance, ctx.topt); check_function_plugin(); if (!ctx.output) |