Re: [PATCH] hfsplus: free failed b-tree nodes in hfs_bnode_put()
From: Markus Elfring
Date: Mon Oct 26 2026 - 14:01:18 EST
…
> +++ b/fs/hfsplus/bnode.c
> @@ -702,6 +702,14 @@ void hfs_bnode_put(struct hfs_bnode *node)
> hfs_bnode_free(node);
> return;
> }
> +
> + if (test_bit(HFS_BNODE_ERROR, &node->flags)) {
> + hfs_bnode_unhash(node);
> + spin_unlock(&tree->hash_lock);
> + hfs_bnode_free(node);
> + return;
> + }
…
How do you think about to avoid a bit of duplicate source code?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?h=v7.3#n526
Regards,
Markus