[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PATCH v3 1/5] tests: fix memory leak in virtio-scsi-test
From: |
Greg Kurz |
Subject: |
Re: [Qemu-ppc] [PATCH v3 1/5] tests: fix memory leak in virtio-scsi-test |
Date: |
Sun, 2 Oct 2016 10:30:51 +0200 |
On Sat, 1 Oct 2016 20:56:00 +0200
Laurent Vivier <address@hidden> wrote:
> vs is allocated in qvirtio_scsi_pci_init() and never freed.
>
> Signed-off-by: Laurent Vivier <address@hidden>
> ---
Reviewed-by: Greg Kurz <address@hidden>
> tests/virtio-scsi-test.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tests/virtio-scsi-test.c b/tests/virtio-scsi-test.c
> index 79088bb..94d75b1 100644
> --- a/tests/virtio-scsi-test.c
> +++ b/tests/virtio-scsi-test.c
> @@ -64,6 +64,7 @@ static void qvirtio_scsi_pci_free(QVirtIOSCSI *vs)
> qvirtio_pci_device_disable(container_of(vs->dev, QVirtioPCIDevice,
> vdev));
> g_free(vs->dev);
> qpci_free_pc(vs->bus);
> + g_free(vs);
> }
>
> static uint64_t qvirtio_scsi_alloc(QVirtIOSCSI *vs, size_t alloc_size,
[Qemu-ppc] [PATCH v3 5/5] tests: enable virtio tests on SPAPR, Laurent Vivier, 2016/10/01