linux/tools
Steven Rostedt dd4b0cc442 tools lib traceevent: Do not reassign parg after collapse_tree()
[ Upstream commit 106b816cb4 ]

At the end of process_filter(), collapse_tree() was changed to update
the parg parameter, but the reassignment after the call wasn't removed.

What happens is that the "current_op" gets modified and freed and parg
is assigned to the new allocated argument. But after the call to
collapse_tree(), parg is assigned again to the just freed "current_op",
and this causes the tool to crash.

The current_op variable must also be assigned to NULL in case of error,
otherwise it will cause it to be free()ed twice.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: stable@vger.kernel.org # 3.14+
Fixes: 42d6194d13 ("tools lib traceevent: Refactor process_filter()")
Link: http://lkml.kernel.org/r/20160511150936.678c18a1@gandalf.local.home
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
History 2016-05-17 22:05:21 -04:00
..
cgroup cgroups: fix cgroup_event_listener error handling 2013-01-08 10:00:44 -08:00
firewire tools/firewire: nosy-dump: check for allocation failure 2012-12-02 20:10:18 +01:00
hv tools/hv: Use include/uapi with __EXPORTED_HEADERS__ 2016-04-12 09:11:20 -04:00
include tools: add more endian.h macros 2014-09-26 11:03:01 +02:00
lguest tools/lguest: offer VIRTIO_F_ANY_LAYOUT for net device. 2013-07-15 11:18:32 +09:30
lib tools lib traceevent: Do not reassign parg after collapse_tree() 2016-05-17 22:05:21 -04:00
net tools/net: Use include/uapi with __EXPORTED_HEADERS__ 2015-12-14 12:19:21 -05:00
nfsd NFSD: Added fault injection script 2011-11-07 21:10:47 -05:00
perf perf tools: Dont stop PMU parsing on alias parse error 2016-04-18 08:49:17 -04:00
power tools/power turbostat: Use $(CURDIR) instead of $(PWD) and add support for O= option in Makefile 2015-05-17 19:12:09 -04:00
scripts tools lib traceevent: Add global QUIET_CC_FPIC build output 2013-12-19 16:18:10 -03:00
testing efi: Make efivarfs entries immutable by default 2016-04-12 17:06:28 -04:00
thermal/tmon tmon: set umask to a reasonable value 2014-07-01 22:00:51 +08:00
time tools: add script to test udelay 2014-07-23 10:16:38 -07:00
usb Linux 3.17-rc5 2014-09-16 09:53:59 -05:00
virtio tools: Consolidate types.h 2014-05-01 21:22:39 +02:00
vm Revert "tools/vm: fix page-flags build" 2015-06-15 13:44:18 -04:00
Makefile tools: Add a "make all" rule 2016-03-13 13:53:42 -04:00