提交 6adb0b0a 编写于 作者: D David Ahern 提交者: Arnaldo Carvalho de Melo

perf tools: Add default handler for mmap2 events

Commands that do not implement an mmap2 handler should at least not die
with a segfault when processing files with MMAP2 events.
Signed-off-by: NDavid Ahern <dsahern@gmail.com>
Link: http://lkml.kernel.org/r/1379900700-5186-5-git-send-email-dsahern@gmail.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
上级 d8b11a0c
...@@ -256,6 +256,8 @@ void perf_tool__fill_defaults(struct perf_tool *tool) ...@@ -256,6 +256,8 @@ void perf_tool__fill_defaults(struct perf_tool *tool)
tool->sample = process_event_sample_stub; tool->sample = process_event_sample_stub;
if (tool->mmap == NULL) if (tool->mmap == NULL)
tool->mmap = process_event_stub; tool->mmap = process_event_stub;
if (tool->mmap2 == NULL)
tool->mmap2 = process_event_stub;
if (tool->comm == NULL) if (tool->comm == NULL)
tool->comm = process_event_stub; tool->comm = process_event_stub;
if (tool->fork == NULL) if (tool->fork == NULL)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册