qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PULL v2 089/106] tests: fix memory leak in test of string


From: Michael S. Tsirkin
Subject: [Qemu-devel] [PULL v2 089/106] tests: fix memory leak in test of string input visitor
Date: Wed, 18 Jun 2014 19:21:35 +0300

From: Hu Tao <address@hidden>

Signed-off-by: Hu Tao <address@hidden>
Acked-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
---
 tests/test-string-input-visitor.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/test-string-input-visitor.c 
b/tests/test-string-input-visitor.c
index 877e737..01a78f0 100644
--- a/tests/test-string-input-visitor.c
+++ b/tests/test-string-input-visitor.c
@@ -193,6 +193,7 @@ static void test_visitor_in_fuzz(TestInputVisitorData *data,
 
         v = visitor_input_test_init(data, buf);
         visit_type_int(v, &ires, NULL, NULL);
+        visitor_input_teardown(data, NULL);
 
         v = visitor_input_test_init(data, buf);
         visit_type_bool(v, &bres, NULL, NULL);
@@ -200,11 +201,13 @@ static void test_visitor_in_fuzz(TestInputVisitorData 
*data,
 
         v = visitor_input_test_init(data, buf);
         visit_type_number(v, &nres, NULL, NULL);
+        visitor_input_teardown(data, NULL);
 
         v = visitor_input_test_init(data, buf);
         sres = NULL;
         visit_type_str(v, &sres, NULL, NULL);
         g_free(sres);
+        visitor_input_teardown(data, NULL);
 
         v = visitor_input_test_init(data, buf);
         visit_type_EnumOne(v, &eres, NULL, NULL);
-- 
MST




reply via email to

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