udf: Remove NULL dereference.
authorSascha Wildner <saw@online.de>
Wed, 21 Jan 2009 21:25:12 +0000 (22:25 +0100)
committerSascha Wildner <saw@online.de>
Wed, 21 Jan 2009 21:25:50 +0000 (22:25 +0100)
Even if the conditional wasn't wrong, it would be pointless, because
udfmp->hashtbl is already initialized by phashinit() in udf_mountfs().

Found-by: LLVM/Clang Static Analyzer
sys/vfs/udf/udf_vnops.c

index 8b92396..dc9e49c 100644 (file)
@@ -143,8 +143,6 @@ udf_hashins(struct udf_node *node)
 
        lwkt_gettoken(&hashlock, &udfmp->hash_token);
        lh = &udfmp->hashtbl[node->hash_id % udfmp->hashsz];
-       if (lh == NULL)
-               LIST_INIT(lh);
        LIST_INSERT_HEAD(lh, node, le);
        lwkt_reltoken(&hashlock);