We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e5f40d6 + 7986fea commit 64698d2Copy full SHA for 64698d2
glue/src/lib.rs
@@ -10,6 +10,8 @@ extern crate libc;
10
11
use std::sync::Mutex;
12
13
+use std::thread::Thread;
14
+
15
#[doc(hidden)]
16
pub mod ffi;
17
@@ -79,7 +81,7 @@ pub fn android_main2<F>(app: *mut (), main_function: F)
79
81
app.userData = unsafe { std::mem::transmute(&context) };
80
82
83
// executing the main function in parallel
- spawn(move|| {
84
+ let g = Thread::spawn(move|| {
85
std::io::stdio::set_stdout(box std::io::LineBufferedWriter::new(ToLogWriter));
86
std::io::stdio::set_stderr(box std::io::LineBufferedWriter::new(ToLogWriter));
87
main_function()
0 commit comments