[PATCH] radixtree: normalize radix_tree_tag_get() return value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In radix_tree_tag_get(), return normalized value of 0/1, as indicated
by its comment.

Signed-off-by: Wu Fengguang <[email protected]>
---

--- linux-2.6.17-rc5-mm2.orig/lib/radix-tree.c
+++ linux-2.6.17-rc5-mm2/lib/radix-tree.c
@@ -531,7 +531,7 @@ int radix_tree_tag_get(struct radix_tree
 			int ret = tag_get(slot, tag, offset);
 
 			BUG_ON(ret && saw_unset_tag);
-			return ret;
+			return !! ret;
 		}
 		slot = slot->slots[offset];
 		shift -= RADIX_TREE_MAP_SHIFT;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux