diff options
author | Julia Lawall <julia@diku.dk> | 2012-08-04 23:52:36 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-08-06 13:29:57 -0700 |
commit | f716168b8aee528cf685246f0e7247aa0d08b79c (patch) | |
tree | bfdff5930998734e251535ce40f9ff451cf80963 /init | |
parent | 8e7dfbc8d1ea9ca9058aa641a8fe795ebca320e2 (diff) |
drivers/atm/iphase.c: fix error return code
Convert a 0 error return code to a negative one, as returned elsewhere in the
function.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
identifier ret;
expression e,e1,e2,e3,e4,x;
@@
(
if (\(ret != 0\|ret < 0\) || ...) { ... return ...; }
|
ret = 0
)
... when != ret = e1
*x = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\|ioremap\|ioremap_nocache\|devm_ioremap\|devm_ioremap_nocache\)(...);
... when != x = e2
when != ret = e3
*if (x == NULL || ...)
{
... when != ret = e4
* return ret;
}
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions