From d92551f28eff7cb6572ed3147399e51f5f5dfc22 Mon Sep 17 00:00:00 2001 From: Amit Shah Date: Wed, 27 Jul 2011 14:00:30 +0530 Subject: virtio-blk: Fix memleak on exit Calling virtio_cleanup() will free up memory allocated in virtio_common_init(). Signed-off-by: Amit Shah Signed-off-by: Michael S. Tsirkin --- hw/virtio-blk.c | 1 + 1 file changed, 1 insertion(+) (limited to 'hw/virtio-blk.c') diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c index 6471ac85ab..836dbc3c12 100644 --- a/hw/virtio-blk.c +++ b/hw/virtio-blk.c @@ -594,4 +594,5 @@ void virtio_blk_exit(VirtIODevice *vdev) { VirtIOBlock *s = to_virtio_blk(vdev); unregister_savevm(s->qdev, "virtio-blk", s); + virtio_cleanup(vdev); } -- cgit v1.2.3