]> git.baikalelectronics.ru Git - kernel.git/commit
perf evsel: Fix uninitialized memory access to struct perf_sample
authorRobert Richter <robert.richter@amd.com>
Thu, 15 Dec 2011 16:32:39 +0000 (17:32 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 20 Dec 2011 15:26:47 +0000 (13:26 -0200)
commit0b03d63b85309ae4e67e811b3d487a52018c3701
treedd3962fd82b6cb5e6b8a87a0ba9dbb90c36a7c68
parentef33e0659ce4b93cd069f392ee16941e758e56b9
perf evsel: Fix uninitialized memory access to struct perf_sample

Memory in struct perf_sample is not fully initialized during parsing.
Depending on sampling data some parts may left unchanged. Zero out
struct perf_sample first to avoid access to uninitialized memory.

Cc: Ingo Molnar <mingo@elte.hu>
Link: http://lkml.kernel.org/r/1323966762-8574-2-git-send-email-robert.richter@amd.com
Signed-off-by: Robert Richter <robert.richter@amd.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/evsel.c