Message ID | 20220404111919.3883e905@gandalf.local.home (mailing list archive) |
---|---|
State | Accepted |
Commit | 651cd9257e407423f5886b6e66d352b10ca72d5d |
Headers | show |
Series | trace-cmd library: Use clock local if no clock is found when creating buffer | expand |
diff --git a/lib/trace-cmd/trace-output.c b/lib/trace-cmd/trace-output.c index 73020ff1fda1..f3a203ec347f 100644 --- a/lib/trace-cmd/trace-output.c +++ b/lib/trace-cmd/trace-output.c @@ -2139,6 +2139,10 @@ out_add_buffer_option(struct tracecmd_output *handle, const char *name, return NULL; clock = get_clock(handle); + if (!clock) { + tracecmd_warning("Could not find clock, set to 'local'"); + clock = "local"; + } /* * Buffer flyrecord option: