diff options
| author | Jeff Olson <olson.jeffery@gmail.com> | 2012-04-16 23:21:27 -0700 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-04-20 15:23:22 -0700 |
| commit | 253fad77883869511e2030352e86904ac2165d7c (patch) | |
| tree | ce92967c3a4b2c971104023634b765dbb2dd7123 /src/rt/rust_kernel.cpp | |
| parent | d7a87aa0a1bf6fb2fe2e591d63e48e39799e8437 (diff) | |
| download | rust-253fad77883869511e2030352e86904ac2165d7c.tar.gz rust-253fad77883869511e2030352e86904ac2165d7c.zip | |
replace impl of globa_async_handle with one using atomic compare-and-swap
Diffstat (limited to 'src/rt/rust_kernel.cpp')
| -rw-r--r-- | src/rt/rust_kernel.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/rt/rust_kernel.cpp b/src/rt/rust_kernel.cpp index 1ff6fad64ab..9afb010a3db 100644 --- a/src/rt/rust_kernel.cpp +++ b/src/rt/rust_kernel.cpp @@ -27,10 +27,9 @@ rust_kernel::rust_kernel(rust_env *env) : // set up storage of pointers needed to // access the global loop. global_loop_chan = 0; - int foo = 0; - async_handle_stub = (void*)&foo; - global_async_handle = &async_handle_stub; - *global_async_handle = (void*)0; + async_handle_inner = (uintptr_t)0; + global_async_handle = &async_handle_inner; + *global_async_handle = (uintptr_t)0; // Create the single threaded scheduler that will run on the platform's // main thread |
