Skip to content

Commit 93c4c03

Browse files
lorddoskiaskdave
authored andcommitted
btrfs: remove fail label in check_compressed_csum
Signed-off-by: Nikolay Borisov <[email protected]> Reviewed-by: David Sterba <[email protected]> Signed-off-by: David Sterba <[email protected]>
1 parent b7d2083 commit 93c4c03

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

fs/btrfs/compression.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,6 @@ static int check_compressed_csum(struct btrfs_inode *inode, struct bio *bio,
178178
struct btrfs_fs_info *fs_info = inode->root->fs_info;
179179
SHASH_DESC_ON_STACK(shash, fs_info->csum_shash);
180180
const u16 csum_size = btrfs_super_csum_size(fs_info->super_copy);
181-
int ret;
182181
struct page *page;
183182
unsigned long i;
184183
char *kaddr;
@@ -205,15 +204,11 @@ static int check_compressed_csum(struct btrfs_inode *inode, struct bio *bio,
205204
btrfs_dev_stat_inc_and_print(
206205
btrfs_io_bio(bio)->device,
207206
BTRFS_DEV_STAT_CORRUPTION_ERRS);
208-
ret = -EIO;
209-
goto fail;
207+
return -EIO;
210208
}
211209
cb_sum += csum_size;
212-
213210
}
214-
ret = 0;
215-
fail:
216-
return ret;
211+
return 0;
217212
}
218213

219214
/* when we finish reading compressed pages from the disk, we

0 commit comments

Comments
 (0)