OpenVZ Forum


Home » Mailing lists » Devel » [PATCH 1/6] perf: use event_name() to get an event name
[PATCH 1/6] perf: use event_name() to get an event name [message #44435] Wed, 07 December 2011 13:55
Andrey Vagin is currently offline  Andrey Vagin
Messages: 9
Registered: December 2011
Junior Member
From: *parallels.com
perf_evsel.name may be not initialized

Signed-off-by: Andrew Vagin <avagin@openvz.org>
---
tools/perf/util/header.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c
index 9272f3a..5b01449 100644
--- a/tools/perf/util/header.c
+++ b/tools/perf/util/header.c
@@ -388,7 +388,7 @@ static int write_event_desc(int fd, struct perf_header *h __used,
/*
* write event string as passed on cmdline
*/
- ret = do_write_string(fd, attr->name);
+ ret = do_write_string(fd, event_name(attr));
if (ret < 0)
return ret;
/*
--
1.7.1
Previous Topic: [PATCH] SUNRPC: create svc_xprt in proper network namespace
Next Topic: [PATCH 2/6] perf: add ability to change event according to sample (v3)
Goto Forum:
  


Current Time: Sat Aug 17 23:39:14 GMT 2019