Skip to content

Commit 6340cfe

Browse files
avaginacmel
authored andcommitted
perf header: Use event_name() to get an event name
perf_evsel.name may be not initialized Cc: David Ahern <dsahern@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Arun Sharma <asharma@fb.com> Cc: devel@openvz.org Link: http://lkml.kernel.org/r/1322471015-107825-2-git-send-email-avagin@openvz.org Signed-off-by: Andrew Vagin <avagin@openvz.org> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 38f6ae1 commit 6340cfe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎tools/perf/util/header.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ static int write_event_desc(int fd, struct perf_header *h __used,
388388
/*
389389
* write event string as passed on cmdline
390390
*/
391-
ret = do_write_string(fd, attr->name);
391+
ret = do_write_string(fd, event_name(attr));
392392
if (ret < 0)
393393
return ret;
394394
/*

0 commit comments

Comments
 (0)