qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 1/3] qdev: Fix memory leak in function set_pci_d


From: Stefan Weil
Subject: Re: [Qemu-devel] [PATCH 1/3] qdev: Fix memory leak in function set_pci_devfn
Date: Sat, 28 Apr 2012 14:36:11 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.16) Gecko/20120317 Iceowl/1.0b1 Icedove/3.0.11

Am 28.04.2012 14:24, schrieb Andreas Färber:
Am 28.04.2012 14:20, schrieb Stefan Weil:
Valgrind reported this memory leak which occured very often.

Test scenario:

qemu-system-i386 (no arguments), only BIOS started, terminate with
monitor command (quit).

Signed-off-by: Stefan Weil<address@hidden>
---
  hw/qdev-properties.c |    1 +
  1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c
index 98dd06a..c212303 100644
--- a/hw/qdev-properties.c
+++ b/hw/qdev-properties.c
@@ -834,6 +834,7 @@ static void set_pci_devfn(Object *obj, Visitor *v, void 
*opaque,

      visit_type_str(v,&str, name,&local_err);
      if (local_err) {
+        g_free(local_err);
Please use error_free() instead.

Andreas

Thanks, I have sent a new patch.

Anthony or Blue, the patches in this series are independent,
so it's possible to skip patch 1/3.

Regards,

Stefan W.




reply via email to

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