aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/btrfs')
-rw-r--r--fs/btrfs/qgroup.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/btrfs/qgroup.c b/fs/btrfs/qgroup.c
index 74b432d0b703..c6ce64276869 100644
--- a/fs/btrfs/qgroup.c
+++ b/fs/btrfs/qgroup.c
@@ -430,8 +430,10 @@ out:
430 } 430 }
431 btrfs_free_path(path); 431 btrfs_free_path(path);
432 432
433 if (ret < 0) 433 if (ret < 0) {
434 ulist_free(fs_info->qgroup_ulist); 434 ulist_free(fs_info->qgroup_ulist);
435 fs_info->qgroup_ulist = NULL;
436 }
435 437
436 return ret < 0 ? ret : 0; 438 return ret < 0 ? ret : 0;
437} 439}
@@ -932,8 +934,10 @@ out_free_root:
932 kfree(quota_root); 934 kfree(quota_root);
933 } 935 }
934out: 936out:
935 if (ret) 937 if (ret) {
936 ulist_free(fs_info->qgroup_ulist); 938 ulist_free(fs_info->qgroup_ulist);
939 fs_info->qgroup_ulist = NULL;
940 }
937 mutex_unlock(&fs_info->qgroup_ioctl_lock); 941 mutex_unlock(&fs_info->qgroup_ioctl_lock);
938 return ret; 942 return ret;
939} 943}