aboutsummaryrefslogtreecommitdiff
path: root/block/qcow2.c
diff options
context:
space:
mode:
authorMichael Tokarev <mjt@tls.msk.ru>2012-06-07 20:21:06 +0400
committerMichael Tokarev <mjt@tls.msk.ru>2012-06-11 23:12:11 +0400
commitd5e6b1619c516fa1e2ee4d8d20f08fcda4fb67a0 (patch)
tree20ea66644af8533a7ce32f51875d50a800e9b7d4 /block/qcow2.c
parent1b093c480a32051cc856b6ab2395d8cbc3ae99da (diff)
change qemu_iovec_to_buf() to match other to,from_buf functions
It now allows specifying offset within qiov to start from and amount of bytes to copy. Actual implementation is just a call to iov_to_buf(). Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'block/qcow2.c')
-rw-r--r--block/qcow2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/qcow2.c b/block/qcow2.c
index 8458d10c10..1b5b36cfc1 100644
--- a/block/qcow2.c
+++ b/block/qcow2.c
@@ -731,7 +731,7 @@ static coroutine_fn int qcow2_co_writev(BlockDriverState *bs,
assert(hd_qiov.size <=
QCOW_MAX_CRYPT_CLUSTERS * s->cluster_size);
- qemu_iovec_to_buffer(&hd_qiov, cluster_data);
+ qemu_iovec_to_buf(&hd_qiov, 0, cluster_data, hd_qiov.size);
qcow2_encrypt_sectors(s, sector_num, cluster_data,
cluster_data, cur_nr_sectors, 1, &s->aes_encrypt_key);