Re: [PATCH] virtio: qmp: fix memory leak

2023-05-26 Thread Daniel P . Berrangé
On Fri, May 26, 2023 at 12:24:53PM +0200, Paolo Bonzini wrote: > The VirtioInfoList is already allocated by QAPI_LIST_PREPEND and > need not be allocated by the caller. > > Fixes Coverity CID 1508724. > > Signed-off-by: Paolo Bonzini > --- > hw/virtio/virtio-qmp.c | 11 +-- > 1 file cha

[PATCH] virtio: qmp: fix memory leak

2023-05-26 Thread Paolo Bonzini
The VirtioInfoList is already allocated by QAPI_LIST_PREPEND and need not be allocated by the caller. Fixes Coverity CID 1508724. Signed-off-by: Paolo Bonzini --- hw/virtio/virtio-qmp.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/hw/virtio/virtio-qmp.c b/hw/v