virtio: Plug memleak by freeing vdev
commit845f85fa1597c72609bd10a37b9586b445c13d49
authorAmit Shah <amit.shah@redhat.com>
Wed, 27 Jul 2011 08:30:32 +0000 (27 14:00 +0530)
committerMichael S. Tsirkin <mst@redhat.com>
Wed, 27 Jul 2011 17:19:27 +0000 (27 20:19 +0300)
tree07f02316413edb06bb2e5b95c4507a492acbdaaa
parentb52dfd71f33b902e612b12f6cc89f3b61e4d3e22
virtio: Plug memleak by freeing vdev

virtio_common_init() allocates RAM for the vdev struct (and any
additional memory, depending on the size passed to the function).  This
memory wasn't being freed until now.

Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/virtio.c