diff options
Diffstat (limited to 'fs/btrfs/transaction.c')
-rw-r--r-- | fs/btrfs/transaction.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c index 9630f10f8e1e..511839c04f11 100644 --- a/fs/btrfs/transaction.c +++ b/fs/btrfs/transaction.c | |||
@@ -1284,11 +1284,13 @@ static noinline int create_pending_snapshot(struct btrfs_trans_handle *trans, | |||
1284 | goto fail; | 1284 | goto fail; |
1285 | } | 1285 | } |
1286 | 1286 | ||
1287 | pending->error = btrfs_qgroup_inherit(trans, fs_info, | 1287 | ret = btrfs_qgroup_inherit(trans, fs_info, |
1288 | root->root_key.objectid, | 1288 | root->root_key.objectid, |
1289 | objectid, pending->inherit); | 1289 | objectid, pending->inherit); |
1290 | if (pending->error) | 1290 | if (ret) { |
1291 | goto no_free_objectid; | 1291 | btrfs_abort_transaction(trans, root, ret); |
1292 | goto fail; | ||
1293 | } | ||
1292 | 1294 | ||
1293 | /* see comments in should_cow_block() */ | 1295 | /* see comments in should_cow_block() */ |
1294 | set_bit(BTRFS_ROOT_FORCE_COW, &root->state); | 1296 | set_bit(BTRFS_ROOT_FORCE_COW, &root->state); |