提交 a3941ec1 编写于 作者: R Roel Kluin 提交者: Jens Axboe

loop: don't increment p->offset with (size_t) -EINVAL

Upon a 'transfer error block' size is set to -EINVAL, but this becomes positive
since size is unsigned: p->offset still gets incremented.
Signed-off-by: NRoel Kluin <roel.kluin@gmail.com>
Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
上级 5e18cfd0
......@@ -392,8 +392,7 @@ lo_splice_actor(struct pipe_inode_info *pipe, struct pipe_buffer *buf,
struct loop_device *lo = p->lo;
struct page *page = buf->page;
sector_t IV;
size_t size;
int ret;
int size, ret;
ret = buf->ops->confirm(pipe, buf);
if (unlikely(ret))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册