diff options
-rw-r--r-- | tools/perf/util/values.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/values.c b/tools/perf/util/values.c index 9ac36bf2c438..2c4af02f08cd 100644 --- a/tools/perf/util/values.c +++ b/tools/perf/util/values.c @@ -131,7 +131,7 @@ static int perf_read_values__enlarge_counters(struct perf_read_values *values) for (i = 0; i < values->threads; i++) { u64 *value = realloc(values->value[i], counters_max * sizeof(**values->value)); - if (value) { + if (!value) { pr_debug("failed to enlarge read_values ->values array"); goto out_free_name; } |