diff options
author | Julia Lawall <[email protected]> | 2011-05-13 15:52:09 +0200 |
---|---|---|
committer | Ingo Molnar <[email protected]> | 2011-05-13 17:11:02 +0200 |
commit | d9a5ac9ef306eb5cc874f285185a15c303c50009 (patch) | |
tree | cceb99495c7e2fb07a24d743fc864e049ca96560 /tools/perf/util/scripting-engines/trace-event-python.c | |
parent | 77ed23f8d995a01cd8101d84351b567bf5177a30 (diff) |
x86, mce, AMD: Fix leaving freed data in a list
b may be added to a list, but is not removed before being freed
in the case of an error. This is done in the corresponding
deallocation function, so the code here has been changed to
follow that.
The sematic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)
// <smpl>
@@
expression E,E1,E2;
identifier l;
@@
*list_add(&E->l,E1);
... when != E1
when != list_del(&E->l)
when != list_del_init(&E->l)
when != E = E2
*kfree(E);// </smpl>
Signed-off-by: Julia Lawall <[email protected]>
Cc: Borislav Petkov <[email protected]>
Cc: Robert Richter <[email protected]>
Cc: Yinghai Lu <[email protected]>
Cc: Andreas Herrmann <[email protected]>
Cc: <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions