diff options
Diffstat (limited to 'tools/perf/ui/hist.c')
-rw-r--r-- | tools/perf/ui/hist.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/perf/ui/hist.c b/tools/perf/ui/hist.c index 108e5ed67621..1785bab7adfd 100644 --- a/tools/perf/ui/hist.c +++ b/tools/perf/ui/hist.c | |||
@@ -389,10 +389,13 @@ static int hpp__width_formula(struct perf_hpp *hpp __maybe_unused) | |||
389 | 389 | ||
390 | static int hpp__entry_formula(struct perf_hpp *hpp, struct hist_entry *he) | 390 | static int hpp__entry_formula(struct perf_hpp *hpp, struct hist_entry *he) |
391 | { | 391 | { |
392 | struct hist_entry *pair = hist_entry__next_pair(he); | ||
392 | const char *fmt = symbol_conf.field_sep ? "%s" : "%-70s"; | 393 | const char *fmt = symbol_conf.field_sep ? "%s" : "%-70s"; |
393 | char buf[96] = " "; | 394 | char buf[96] = " "; |
394 | 395 | ||
395 | perf_diff__formula(buf, sizeof(buf), he); | 396 | if (pair) |
397 | perf_diff__formula(he, pair, buf, sizeof(buf)); | ||
398 | |||
396 | return scnprintf(hpp->buf, hpp->size, fmt, buf); | 399 | return scnprintf(hpp->buf, hpp->size, fmt, buf); |
397 | } | 400 | } |
398 | 401 | ||