Kevin Wolf 5a0f6fd5c8 mirror: Fix qiov size for short requests
When mirroring an image of a size that is not a multiple of the
mirror job granularity, the last request would have the right nb_sectors
argument, but a qiov that is rounded up to the next multiple of the
granularity. Don't do this.

This fixes a segfault that is caused by raw-posix being confused by this
and allocating a buffer with request length, but operating on it with
qiov length.

[s/Driver/Drive/ in qemu-iotests 041 as suggested by Eric
--Stefan]

Reported-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Tested-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2014-07-07 09:15:29 +02:00
..
2014-06-23 11:01:25 -04:00
2014-06-16 17:23:21 +08:00
2014-06-24 20:01:24 +04:00
2014-06-26 13:51:01 +02:00
2014-07-01 10:15:12 +02:00
2014-06-16 17:23:21 +08:00
2014-06-16 17:23:21 +08:00
2014-06-16 17:23:21 +08:00
2014-06-16 17:23:21 +08:00
2014-07-01 10:15:12 +02:00
2014-06-16 17:23:21 +08:00
2014-07-01 10:15:12 +02:00
2014-07-01 10:15:12 +02:00
2014-06-16 17:23:21 +08:00