[PATCH 3/6] reiserfs: fix sparse warning in namei.c

From: Harvey Harrison
Date: Mon Feb 18 2008 - 15:53:03 EST


fs/reiserfs/namei.c:455:17: warning: Using plain integer as NULL pointer

Signed-off-by: Harvey Harrison <harvey.harrison@xxxxxxxxx>
---
fs/reiserfs/namei.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/reiserfs/namei.c b/fs/reiserfs/namei.c
index b378eea..8867533 100644
--- a/fs/reiserfs/namei.c
+++ b/fs/reiserfs/namei.c
@@ -452,7 +452,7 @@ static int reiserfs_add_entry(struct reiserfs_transaction_handle *th,
buflen = DEH_SIZE + ROUND_UP(namelen);
if (buflen > sizeof(small_buf)) {
buffer = kmalloc(buflen, GFP_NOFS);
- if (buffer == 0)
+ if (!buffer)
return -ENOMEM;
} else
buffer = small_buf;
--
1.5.4.1.1278.gc75be


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/