diff options
author | Julia Lawall <julia@diku.dk> | 2010-02-06 08:45:15 +0000 |
---|---|---|
committer | Alex Elder <aelder@sgi.com> | 2010-02-13 13:22:53 -0600 |
commit | d67b1b03254c501fef371b0e5916c94a52bfc2c5 (patch) | |
tree | 87d3505cb841844055c113fd9eea124ed31e2ba0 /fs/sysfs/sysfs.h | |
parent | 180040b89ee2aed88c0a0b1fcf7ada9a512b12e3 (diff) | |
download | kernel_samsung_aries-d67b1b03254c501fef371b0e5916c94a52bfc2c5.zip kernel_samsung_aries-d67b1b03254c501fef371b0e5916c94a52bfc2c5.tar.gz kernel_samsung_aries-d67b1b03254c501fef371b0e5916c94a52bfc2c5.tar.bz2 |
fs/xfs: 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>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/sysfs/sysfs.h')
0 files changed, 0 insertions, 0 deletions