diff options
Diffstat (limited to 'tools/perf/util/probe-event.c')
-rw-r--r-- | tools/perf/util/probe-event.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index ab6f53deabad..19de8b77973d 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c | |||
@@ -481,6 +481,10 @@ static void parse_perf_probe_arg(const char *str, struct perf_probe_arg *arg) | |||
481 | } while (tmp); | 481 | } while (tmp); |
482 | (*fieldp)->name = xstrdup(str); | 482 | (*fieldp)->name = xstrdup(str); |
483 | pr_debug("%s(%d)\n", (*fieldp)->name, (*fieldp)->ref); | 483 | pr_debug("%s(%d)\n", (*fieldp)->name, (*fieldp)->ref); |
484 | |||
485 | /* If no name is specified, set the last field name */ | ||
486 | if (!arg->name) | ||
487 | arg->name = xstrdup((*fieldp)->name); | ||
484 | } | 488 | } |
485 | 489 | ||
486 | /* Parse perf-probe event command */ | 490 | /* Parse perf-probe event command */ |