summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSimon Rettberg2022-12-07 16:16:00 +0100
committerSimon Rettberg2022-12-07 16:16:00 +0100
commit38fa6feebd2f00309b96388f85e6865d5c25f6f5 (patch)
treedd3f0a01c4d994f324b002eea010377f7262f6e8 /src
parentDon't use close_range as it might or might not collide with libc (diff)
downloadxloop-38fa6feebd2f00309b96388f85e6865d5c25f6f5.tar.gz
xloop-38fa6feebd2f00309b96388f85e6865d5c25f6f5.tar.xz
xloop-38fa6feebd2f00309b96388f85e6865d5c25f6f5.zip
[KERNEL] Fix a copy/paste error acessing wrong variable in sanity check
Diffstat (limited to 'src')
-rw-r--r--src/kernel/xloop_file_fmt_qcow_main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/kernel/xloop_file_fmt_qcow_main.c b/src/kernel/xloop_file_fmt_qcow_main.c
index 8eb7b52..4764435 100644
--- a/src/kernel/xloop_file_fmt_qcow_main.c
+++ b/src/kernel/xloop_file_fmt_qcow_main.c
@@ -1129,7 +1129,7 @@ static int __qcow_file_fmt_read_bvec(struct xloop_file_fmt *xlo_fmt, struct bio_
mutex_unlock(&qcow_data->global_mutex);
if (ret < 0)
goto fail;
- if (len == 0) {
+ if (ret == 0) {
dev_err(xloop_file_fmt_to_dev(xlo_fmt), "Unexpected empty read in compressed cluster\n");
ret = -EIO;
goto fail;