diff options
| author | Erick Tryzelaar <erick.tryzelaar@gmail.com> | 2013-08-09 18:48:01 -0700 |
|---|---|---|
| committer | Erick Tryzelaar <erick.tryzelaar@gmail.com> | 2013-08-09 18:48:01 -0700 |
| commit | ee59aacac490edd619db1c4e2fcd848f793bc3b9 (patch) | |
| tree | d4f01cefe67f55b80cfaca641a03b581823eb200 /src/libstd/sys.rs | |
| parent | cab6d46e58ea6f7535d8e454f0345eccfae183c4 (diff) | |
| parent | 6f6dce7bbcfb104a8a1e23b0b93d83cbb770f338 (diff) | |
| download | rust-ee59aacac490edd619db1c4e2fcd848f793bc3b9.tar.gz rust-ee59aacac490edd619db1c4e2fcd848f793bc3b9.zip | |
Merge remote-tracking branch 'remotes/origin/master' into remove-str-trailing-nulls
Diffstat (limited to 'src/libstd/sys.rs')
| -rw-r--r-- | src/libstd/sys.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/sys.rs b/src/libstd/sys.rs index 83ee4cf07c6..3add87bbd1d 100644 --- a/src/libstd/sys.rs +++ b/src/libstd/sys.rs @@ -136,7 +136,7 @@ impl FailWithCause for &'static str { pub fn begin_unwind_(msg: *c_char, file: *c_char, line: size_t) -> ! { use either::Left; use option::{Some, None}; - use rt::{context, OldTaskContext, TaskContext}; + use rt::{context, OldTaskContext, in_green_task_context}; use rt::task::Task; use rt::local::Local; use rt::logging::Logger; @@ -158,7 +158,7 @@ pub fn begin_unwind_(msg: *c_char, file: *c_char, line: size_t) -> ! { // XXX: Logging doesn't work correctly in non-task context because it // invokes the local heap - if context == TaskContext { + if in_green_task_context() { // XXX: Logging doesn't work here - the check to call the log // function never passes - so calling the log function directly. do Local::borrow::<Task, ()> |task| { |
