[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH 2/2] iov: assert that qiov->size doesn't exceed

From: Alberto Garcia
Subject: Re: [Qemu-block] [PATCH 2/2] iov: assert that qiov->size doesn't exceed INT_MAX
Date: Wed, 01 Feb 2017 22:55:24 +0100
User-agent: Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu)

On Wed 01 Feb 2017 10:51:01 PM CET, Max Reitz <address@hidden> wrote:

> The assertion probably makes sense even for them, considering that
> size_t does not have a constant size. But I'm not entirely sold that
> the I/O vector creation is actually the place where the assertions
> belong.

I was actually just reading virtio_blk_handle_request() and I see that
the I/O vector is initialized before the check for the maximum request
size that returns VIRTIO_BLK_S_IOERR.

So you're probably right and it's safer not to add that assertion.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]