btrfs: fix return value check of btrfs_start_transaction()
The error check of btrfs_start_transaction() is added, and the mistake of the error check on several places is corrected. Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com> Signed-off-by: Chris Mason <chris.mason@oracle.com>
This commit is contained in:
committed by
Chris Mason
parent
5df6708348
commit
98d5dc13e7
@@ -2357,6 +2357,7 @@ void btrfs_orphan_cleanup(struct btrfs_root *root)
|
||||
*/
|
||||
if (is_bad_inode(inode)) {
|
||||
trans = btrfs_start_transaction(root, 0);
|
||||
BUG_ON(IS_ERR(trans));
|
||||
btrfs_orphan_del(trans, inode);
|
||||
btrfs_end_transaction(trans, root);
|
||||
iput(inode);
|
||||
|
Reference in New Issue
Block a user