diff options
author | David Sterba <dsterba@suse.cz> | 2015-02-24 18:57:18 +0100 |
---|---|---|
committer | Jiri Slaby <jslaby@suse.cz> | 2015-03-12 17:31:10 +0100 |
commit | 3caad0eda3f36aadd1be4655d431814d2c0b21f7 (patch) | |
tree | 5a29eccd608959e699cea89c3584d0602a61439d /fs/btrfs/inode.c | |
parent | 8607e6ba3f48a3bab9476c5afd2e3913387eadd7 (diff) | |
download | lwn-3caad0eda3f36aadd1be4655d431814d2c0b21f7.tar.gz lwn-3caad0eda3f36aadd1be4655d431814d2c0b21f7.zip |
btrfs: fix lost return value due to variable shadowing
commit 1932b7be973b554ffe20a5bba6ffaed6fa995cdc upstream.
A block-local variable stores error code but btrfs_get_blocks_direct may
not return it in the end as there's a ret defined in the function scope.
Fixes: d187663ef24c ("Btrfs: lock extents as we map them in DIO")
Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Chris Mason <clm@fb.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 68f7a1ff104a..904ed6d7e4bb 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -6703,7 +6703,6 @@ static int btrfs_get_blocks_direct(struct inode *inode, sector_t iblock, ((BTRFS_I(inode)->flags & BTRFS_INODE_NODATACOW) && em->block_start != EXTENT_MAP_HOLE)) { int type; - int ret; u64 block_start, orig_start, orig_block_len, ram_bytes; if (test_bit(EXTENT_FLAG_PREALLOC, &em->flags)) |