Skip to content

Commit

Permalink
win32-aio: Fix vectored reads
Browse files Browse the repository at this point in the history
Copying data in the right direction really helps a lot!

Cc: qemu-stable@nongnu.org
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
  • Loading branch information
kevmw authored and stefanhaRH committed Jan 17, 2013
1 parent 2ea9b58 commit bcbbd23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion block/win32-aio.c
Expand Up @@ -84,7 +84,7 @@ static void win32_aio_process_completion(QEMUWin32AIOState *s,
int i;

for (i = 0; i < qiov->niov; ++i) {
memcpy(p, qiov->iov[i].iov_base, qiov->iov[i].iov_len);
memcpy(qiov->iov[i].iov_base, p, qiov->iov[i].iov_len);
p += qiov->iov[i].iov_len;
}
qemu_vfree(waiocb->buf);
Expand Down

0 comments on commit bcbbd23

Please sign in to comment.