From 43ae4b3301cc0605839778ecf59effb32b752e33 Mon Sep 17 00:00:00 2001 From: Aaron Turon Date: Sat, 6 Dec 2014 18:34:37 -0800 Subject: Fallout from new thread API --- src/libstd/sys/windows/stack_overflow.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src/libstd/sys/windows') diff --git a/src/libstd/sys/windows/stack_overflow.rs b/src/libstd/sys/windows/stack_overflow.rs index e3d96a054f4..63b5b6f5863 100644 --- a/src/libstd/sys/windows/stack_overflow.rs +++ b/src/libstd/sys/windows/stack_overflow.rs @@ -8,15 +8,13 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use rt::local::Local; -use rt::task::Task; use rt::util::report_overflow; use core::prelude::*; use ptr; use mem; use libc; use libc::types::os::arch::extra::{LPVOID, DWORD, LONG, BOOL}; -use sys_common::stack; +use sys_common::{stack, thread_info}; pub struct Handler { _data: *mut libc::c_void @@ -37,8 +35,7 @@ impl Drop for Handler { // guard page doesn't exist. None is returned if there's currently // no local task. unsafe fn get_task_guard_page() -> Option { - let task: Option<*mut Task> = Local::try_unsafe_borrow(); - task.map(|task| (&*task).stack_guard().unwrap_or(0)) + thread_info::stack_guard() } // This is initialized in init() and only read from after -- cgit 1.4.1-3-g733a5