提交 db529aab 编写于 作者: A Andreas Färber

vl.c: Guard against GThread double-initialization

GThread-ERROR **: GThread system may only be initialized once.
aborting...

Making the g_thread_init() call in vl.c conditional resolves an abort on
Mac OS X, where coroutine-gthread.c seems to call it before vl.c.
Reported-by: NJuan Pineda <juan@logician.com>
Signed-off-by: NAndreas Färber <andreas.faerber@web.de>
Cc: Daniel P. Berrange <berrange@redhat.com>
上级 351f1bf6
......@@ -2185,7 +2185,9 @@ int main(int argc, char **argv, char **envp)
error_set_progname(argv[0]);
g_mem_set_vtable(&mem_trace);
g_thread_init(NULL);
if (!g_thread_supported()) {
g_thread_init(NULL);
}
runstate_init();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册