diff options
author | David Sterba <dsterba@suse.com> | 2016-05-25 22:51:02 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-05-25 22:51:02 +0200 |
commit | e73440868fde7cce4a93583a4fa2db9a8938a7ed (patch) | |
tree | 4149ed8954a0c344b354769d1c9bbed9a8e54114 /fs/btrfs/extent_io.c | |
parent | c315ef8d9db7f1a0ebd023a395ebdfde1c68057e (diff) | |
parent | f1fee6534dcfbf468a159789aa202db2bce8c200 (diff) |
Merge branch 'misc-4.7' into for-chris-4.7-20160525
Diffstat (limited to 'fs/btrfs/extent_io.c')
-rw-r--r-- | fs/btrfs/extent_io.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 2f83448d34fe..f661688c2102 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -4389,8 +4389,12 @@ int extent_fiemap(struct inode *inode, struct fiemap_extent_info *fieinfo, if (ret < 0) { btrfs_free_path(path); return ret; + } else { + WARN_ON(!ret); + if (ret == 1) + ret = 0; } - WARN_ON(!ret); + path->slots[0]--; btrfs_item_key_to_cpu(path->nodes[0], &found_key, path->slots[0]); found_type = found_key.type; |