qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PULL 14/15] audio: fix memory leak reported by ASAN


From: Gerd Hoffmann
Subject: [Qemu-devel] [PULL 14/15] audio: fix memory leak reported by ASAN
Date: Tue, 13 Aug 2019 13:18:08 +0200

From: Kővágó, Zoltán <address@hidden>

Signed-off-by: Kővágó, Zoltán <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>
---
 audio/audio.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/audio/audio.c b/audio/audio.c
index d3c639211d43..ebe49f3ca10a 100644
--- a/audio/audio.c
+++ b/audio/audio.c
@@ -1343,6 +1343,12 @@ static void free_audio_state(AudioState *s)
         qapi_free_Audiodev(s->dev);
         s->dev = NULL;
     }
+
+    if (s->ts) {
+        timer_free(s->ts);
+        s->ts = NULL;
+    }
+
     g_free(s);
 }
 
-- 
2.18.1




reply via email to

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