diff options
| author | Julia Lawall <[email protected]> | 2008-07-29 22:33:28 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2008-07-30 09:41:45 -0700 |
| commit | 950d442ad053e660538cdaa6efc0e060c2a65062 (patch) | |
| tree | c980cdf6c6a1a7a0dec19a9368b5445e1fb7db4a /tools/perf/scripts/python | |
| parent | d667b6ddbcdc036a27407c8b2c1243f1dfd69e26 (diff) | |
drivers/video: release mutex in error handling code
The mutex is released on a successful return, so it would seem that it
should be released on an error return as well.
The semantic patch finds this problem is as follows:
(http://www.emn.fr/x-info/coccinelle/)
// <smpl>
@@
expression l;
@@
mutex_lock(l);
... when != mutex_unlock(l)
when any
when strict
(
if (...) { ... when != mutex_unlock(l)
+ mutex_unlock(l);
return ...;
}
|
mutex_unlock(l);
)
// </smpl>
Signed-off-by: Julia Lawall <[email protected]>
Acked-by: Krzysztof Helt <[email protected]>
Acked-by: Ondrej Zajicek <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions