diff options
Diffstat (limited to 'tools/perf/util/probe-event.c')
-rw-r--r-- | tools/perf/util/probe-event.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index 71b0dd590a37..a21b6bf055ac 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c | |||
@@ -310,6 +310,7 @@ int synthesize_perf_probe_point(struct probe_point *pp) | |||
310 | int ret; | 310 | int ret; |
311 | 311 | ||
312 | pp->probes[0] = buf = zalloc(MAX_CMDLEN); | 312 | pp->probes[0] = buf = zalloc(MAX_CMDLEN); |
313 | pp->found = 1; | ||
313 | if (!buf) | 314 | if (!buf) |
314 | die("Failed to allocate memory by zalloc."); | 315 | die("Failed to allocate memory by zalloc."); |
315 | if (pp->offset) { | 316 | if (pp->offset) { |
@@ -332,6 +333,7 @@ int synthesize_perf_probe_point(struct probe_point *pp) | |||
332 | error: | 333 | error: |
333 | free(pp->probes[0]); | 334 | free(pp->probes[0]); |
334 | pp->probes[0] = NULL; | 335 | pp->probes[0] = NULL; |
336 | pp->found = 0; | ||
335 | } | 337 | } |
336 | return ret; | 338 | return ret; |
337 | } | 339 | } |
@@ -494,6 +496,7 @@ void show_perf_probe_events(void) | |||
494 | struct str_node *ent; | 496 | struct str_node *ent; |
495 | 497 | ||
496 | setup_pager(); | 498 | setup_pager(); |
499 | memset(&pp, 0, sizeof(pp)); | ||
497 | 500 | ||
498 | fd = open_kprobe_events(O_RDONLY, 0); | 501 | fd = open_kprobe_events(O_RDONLY, 0); |
499 | rawlist = get_trace_kprobe_event_rawlist(fd); | 502 | rawlist = get_trace_kprobe_event_rawlist(fd); |