Skip to contentSkip to conversation

reiserfs: fix sparse warning in namei.c

PATCH New Harvey Harrison 1 participant 1 message Feb 18, 2008

lore
Share & tools
lore
#0 lore raw

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

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

---
 fs/reiserfs/namei.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fs/reiserfs/namei.c +1 -1
index b378eea..8867533 100644
@@ -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;
Signature · 1 line
1.5.4.1.1278.gc75be