qemu-trivial
[Top][All Lists]
Advanced

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

[PATCH] test-vmstate: Fix memleaks in test_load_qlist


From: kuhn.chenqun
Subject: [PATCH] test-vmstate: Fix memleaks in test_load_qlist
Date: Sat, 15 Feb 2020 12:31:09 +0800

From: Chen Qun <address@hidden>

We may forget to free fload. ASAN spotted it.

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Chen Qun <address@hidden>
---
 tests/test-vmstate.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tests/test-vmstate.c b/tests/test-vmstate.c
index cea363dd69..5b2743121b 100644
--- a/tests/test-vmstate.c
+++ b/tests/test-vmstate.c
@@ -1395,6 +1395,7 @@ static void test_load_qlist(void)
     compare_containers(orig_container, dest_container);
     free_container(orig_container);
     free_container(dest_container);
+    qemu_fclose(fload);
 }
 
 typedef struct TmpTestStruct {
-- 
2.23.0





reply via email to

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