diff options
-rw-r--r-- | hw/virtio-blk.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c index b05d15ecdd..d270225020 100644 --- a/hw/virtio-blk.c +++ b/hw/virtio-blk.c @@ -105,8 +105,10 @@ static void virtio_blk_flush_complete(void *opaque, int ret) static VirtIOBlockReq *virtio_blk_alloc_request(VirtIOBlock *s) { - VirtIOBlockReq *req = qemu_mallocz(sizeof(*req)); + VirtIOBlockReq *req = qemu_malloc(sizeof(*req)); req->dev = s; + req->qiov.size = 0; + req->next = NULL; return req; } |