diff options
author | Su Yue <suy.fnst@cn.fujitsu.com> | 2018-05-30 14:49:10 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-05-30 17:33:58 +0200 |
commit | 9132c4ff6f9557db3ba10fb321317b4f67626ee8 (patch) | |
tree | 685c19639e5d5ab9b980e0632d0ecea6440dc165 /fs/btrfs | |
parent | 1389053e1bed93b75b0c3cd292f61032334c81b3 (diff) |
btrfs: return ENOMEM if path allocation fails in btrfs_cross_ref_exist
The error code does not match the reason of failure and may confuse the
callers.
Signed-off-by: Su Yue <suy.fnst@cn.fujitsu.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/extent-tree.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 9a65df02a13f..3d9fe58c0080 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@ -3272,7 +3272,7 @@ int btrfs_cross_ref_exist(struct btrfs_root *root, u64 objectid, u64 offset, path = btrfs_alloc_path(); if (!path) - return -ENOENT; + return -ENOMEM; do { ret = check_committed_ref(root, path, objectid, |