Skip to content

Commit 29e5256

Browse files
fdmananakdave
authored andcommitted
btrfs: fix lost return value on error in finish_verity()
If btrfs_update_inode() or del_orphan() fail, we jump to the 'end_trans' label and then return 0 instead of the error returned by one of those calls. Fix this and return the error. Fixes: 61fb7f0 ("btrfs: remove out label in finish_verity()") Reported-by: Chris Mason <clm@meta.com> Link: https://lore.kernel.org/linux-btrfs/20260208161129.3888234-1-clm@meta.com/ Reviewed-by: Qu Wenruo <wqu@suse.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
1 parent f46a283 commit 29e5256

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

fs/btrfs/verity.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,7 @@ static int finish_verity(struct btrfs_inode *inode, const void *desc,
552552
btrfs_set_fs_compat_ro(root->fs_info, VERITY);
553553
end_trans:
554554
btrfs_end_transaction(trans);
555-
return 0;
555+
return ret;
556556

557557
}
558558

0 commit comments

Comments
 (0)