From c6667c06c34a25a8a21a1805b4f454f2d05d337c Mon Sep 17 00:00:00 2001 From: Jeff Olson Date: Wed, 11 Apr 2012 22:14:16 -0700 Subject: add needed fields for global libuv loop + bindings to manage from rust adding two pointers fields to rust_kernel :( .. have to do manual malloc/free for one of the fields, which feels wrong --- src/rt/rust_kernel.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/rt/rust_kernel.cpp') diff --git a/src/rt/rust_kernel.cpp b/src/rt/rust_kernel.cpp index a629f2ff4af..2a4315bd842 100644 --- a/src/rt/rust_kernel.cpp +++ b/src/rt/rust_kernel.cpp @@ -24,6 +24,13 @@ rust_kernel::rust_kernel(rust_env *env) : non_weak_tasks(0), env(env) { + // set up storage of pointers needed to + // access the global loop. + global_loop_chan = 0; + global_async_handle = (void**)::malloc( // FIXME -- can use this->malloc() + sizeof(void*)); // .. what do? + *global_async_handle = (void*)0; + // Create the single threaded scheduler that will run on the platform's // main thread rust_manual_sched_launcher_factory launchfac; -- cgit 1.4.1-3-g733a5