提交 5411f3d0 编写于 作者: M Marc-André Lureau 提交者: Thomas Huth

vhost-user-test: fix leaks

Spotted by ASAN.
Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: NThomas Huth <thuth@redhat.com>
Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
Reviewed-by: NStefano Garzarella <sgarzare@redhat.com>
Fixes: ae31fb54 and 4d3f50ebReviewed-by: NPhilippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: NThomas Huth <thuth@redhat.com>
上级 13ee9e30
......@@ -588,6 +588,7 @@ static void test_server_free(TestServer *server)
g_test_message("unable to rmdir: path (%s): %s",
server->tmpfs, strerror(errno));
}
g_free(server->tmpfs);
qemu_chr_fe_deinit(&server->chr, true);
......@@ -605,6 +606,8 @@ static void test_server_free(TestServer *server)
g_main_loop_unref(server->loop);
g_main_context_unref(server->context);
g_cond_clear(&server->data_cond);
g_mutex_clear(&server->data_mutex);
g_free(server);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册