aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/btrfs/ioctl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index da518ded34bd..84bb4de1bb80 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -571,7 +571,8 @@ static int create_snapshot(struct btrfs_root *root, struct dentry *dentry,
571 ret = btrfs_commit_transaction(trans, 571 ret = btrfs_commit_transaction(trans,
572 root->fs_info->extent_root); 572 root->fs_info->extent_root);
573 } 573 }
574 BUG_ON(ret); 574 if (ret)
575 goto fail;
575 576
576 ret = pending_snapshot->error; 577 ret = pending_snapshot->error;
577 if (ret) 578 if (ret)