Skip to contentSkip to conversation

nfs: fix sparse warning in idmap.c

PATCH In review Harvey Harrison 1 participant 1 message Feb 20, 2008 NFS client

lore
Share & tools
lore
#0 lore raw

PATCH 3/4 nfs: fix sparse warning in idmap.c

fs/nfs/idmap.c:312:12: warning: Using plain integer as NULL pointer

---
 fs/nfs/idmap.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fs/nfs/idmap.c +1 -1
index 8ae5dba..86147b0 100644
@@ -309,7 +309,7 @@ nfs_idmap_name(struct idmap *idmap, struct idmap_hashtable *h,
 	mutex_lock(&idmap->idmap_im_lock);
 
 	he = idmap_lookup_id(h, id);
-	if (he != 0) {
+	if (he) {
 		memcpy(name, he->ih_name, he->ih_namelen);
 		ret = he->ih_namelen;
 		goto out;
Signature · 1 line
1.5.4.2.200.g99e75