aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/perf/util/probe-event.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c
index 1c4a20a284c0..6d438391bae5 100644
--- a/tools/perf/util/probe-event.c
+++ b/tools/perf/util/probe-event.c
@@ -806,12 +806,12 @@ static char *synthesize_perf_probe_point(struct perf_probe_point *pp)
806 goto error; 806 goto error;
807 } 807 }
808 if (pp->file) { 808 if (pp->file) {
809 len = strlen(pp->file) - 32; 809 len = strlen(pp->file) - 31;
810 if (len < 0) 810 if (len < 0)
811 len = 0; 811 len = 0;
812 tmp = strchr(pp->file + len, '/'); 812 tmp = strchr(pp->file + len, '/');
813 if (!tmp) 813 if (!tmp)
814 tmp = pp->file + len - 1; 814 tmp = pp->file + len;
815 ret = e_snprintf(file, 32, "@%s", tmp + 1); 815 ret = e_snprintf(file, 32, "@%s", tmp + 1);
816 if (ret <= 0) 816 if (ret <= 0)
817 goto error; 817 goto error;