diff options
| author | Julia Lawall <julia@diku.dk> | 2011-05-16 13:20:29 +0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-05-18 00:31:31 +0400 |
| commit | d93089df1b752e4da048cd7f4749d29120b65e55 (patch) | |
| tree | cd9f5f0985a838fc61fb9192d5b5d6b632b7a0cd /tools/perf/scripts/python | |
| parent | aacd531df9b88f7419e22708f72a476030863efe (diff) | |
| download | linux-d93089df1b752e4da048cd7f4749d29120b65e55.tar.xz | |
drivers/staging/ath6kl/os/linux/cfg80211.c: Add missing call to cfg80211_put_bss
A call to cfg80211_get_bss hould be accompanied by a call to
cfg80211_put_bss in error-handling code.
A simplified version of the semantic match that finds this problem is:
(http://coccinelle.lip6.fr/)
// <smpl>
@r exists@
local idexpression struct cfg80211_bss * x;
expression ra,rr;
position p1,p2;
@@
x = cfg80211_get_bss@p1(...)
... when != x = rr
when != cfg80211_put_bss(x,...)
when != if (...) { ... cfg80211_put_bss(x,...) ...}
if(...) { ... when != x = ra
when forall
when != cfg80211_put_bss(x,...)
\(return <+...x...+>; \| return@p2...; \) }
@script:python@
p1 << r.p1;
p2 << r.p2;
@@
cocci.print_main("cfg80211_get_bss",p1)
cocci.print_secs("return",p2)
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
