[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <tip-b2e19a934a36b2b4affcde9c170c0f01afabe50a@git.kernel.org>
Date: Wed, 15 Oct 2014 22:23:22 -0700
From: tip-bot for Yasser Shalabi <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: mingo@...hat.com, a.p.zijlstra@...llo.nl, namhyung@...nel.org,
tglx@...utronix.de, linux-kernel@...r.kernel.org,
yassershalabi@...il.com, paulus@...ba.org, mingo@...nel.org,
hpa@...or.com, acme@...hat.com
Subject: [tip:perf/urgent] perf evlist: Fix for double free in tools/
perf stat
Commit-ID: b2e19a934a36b2b4affcde9c170c0f01afabe50a
Gitweb: http://git.kernel.org/tip/b2e19a934a36b2b4affcde9c170c0f01afabe50a
Author: Yasser Shalabi <yassershalabi@...il.com>
AuthorDate: Sat, 4 Oct 2014 11:37:57 -0400
Committer: Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Wed, 15 Oct 2014 16:16:53 -0300
perf evlist: Fix for double free in tools/perf stat
Fix for double free bug in tools/perf due to dangling thread_map pointer
in perf_evlist struct.
Code path excercised when perf stat -C switch is used but not set and is
followed by another switch.
Example:
perf stat -C -e.
Signed-off-by: Yasser Shalabi <yassershalabi@...il.com>
Acked-by: Namhyung Kim <namhyung@...nel.org>
Cc: Ingo Molnar <mingo@...hat.com>
Cc: Paul Mackerras <paulus@...ba.org>
Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
Link: http://lkml.kernel.org/r/1412437077-13109-1-git-send-email-yassershalabi@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
tools/perf/util/evlist.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
index b4b54d8..3c9e77d 100644
--- a/tools/perf/util/evlist.c
+++ b/tools/perf/util/evlist.c
@@ -1003,6 +1003,7 @@ int perf_evlist__create_maps(struct perf_evlist *evlist, struct target *target)
out_delete_threads:
thread_map__delete(evlist->threads);
+ evlist->threads = NULL;
return -1;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists