diff options
author | 2010-02-08 22:44:18 -0800 | |
---|---|---|
committer | 2010-02-08 22:44:18 -0800 | |
commit | bcf4d812e66ee95f762b38063d654fd1ff7156b0 (patch) | |
tree | 7b56aa70d64d4f4da6a73cb75974bbc7c05d51e5 /fs/proc/array.c | |
parent | MAINTAINERS: networking drivers - Add git net-next tree (diff) | |
download | linux-dev-bcf4d812e66ee95f762b38063d654fd1ff7156b0.tar.xz linux-dev-bcf4d812e66ee95f762b38063d654fd1ff7156b0.zip |
drivers/net: Correct NULL test
Test the value that was just allocated rather than the previously tested one.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@r@
expression *x;
expression e;
identifier l;
@@
if (x == NULL || ...) {
... when forall
return ...; }
... when != goto l;
when != x = e
when != &x
*x == NULL
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'fs/proc/array.c')
0 files changed, 0 insertions, 0 deletions