[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/8] ide: fix leak from qemu_allocate_irqs

From: Eric Blake
Subject: Re: [PATCH 1/8] ide: fix leak from qemu_allocate_irqs
Date: Tue, 1 Oct 2019 10:28:46 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.0

On 10/1/19 8:36 AM, Paolo Bonzini wrote:
The array returned by qemu_allocate_irqs is malloced, free it.

Signed-off-by: Paolo Bonzini <address@hidden>
  hw/ide/cmd646.c | 1 +
  1 file changed, 1 insertion(+)

diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c
index f3ccd11..19984d2 100644
--- a/hw/ide/cmd646.c
+++ b/hw/ide/cmd646.c
@@ -300,6 +300,7 @@ static void pci_cmd646_ide_realize(PCIDevice *dev, Error 
          d->bmdma[i].bus = &d->bus[i];
+    g_free(irq);

How many of these patches could be fixed by using g_autofree or similar instead?

Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]