From 5a82e8ffdd0f6f664a5e685df358b95871acd5ee Mon Sep 17 00:00:00 2001 From: Josh Matthews Date: Tue, 16 May 2017 17:37:22 -0400 Subject: [PATCH] Revert "Replace intrinsics::abort with process::abort" This reverts commit a239419cc0692cec5a9b35de8d3ad472276b8c1a. --- ports/cef/lib.rs | 1 + ports/cef/stubs.rs | 4 +++- ports/servo/main.rs | 8 +++++--- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ports/cef/lib.rs b/ports/cef/lib.rs index 809fccc412b..f953358e4a9 100644 --- a/ports/cef/lib.rs +++ b/ports/cef/lib.rs @@ -4,6 +4,7 @@ #![allow(non_camel_case_types)] #![feature(box_syntax)] +#![feature(core_intrinsics)] #![feature(link_args)] #[macro_use] diff --git a/ports/cef/stubs.rs b/ports/cef/stubs.rs index df35e050852..8f4a9b73820 100644 --- a/ports/cef/stubs.rs +++ b/ports/cef/stubs.rs @@ -12,7 +12,9 @@ macro_rules! stub( #[allow(non_snake_case)] pub extern "C" fn $name() { println!("CEF stub function called: {}", stringify!($name)); - ::std::process::abort() + unsafe { + ::std::intrinsics::abort() + } } ) ); diff --git a/ports/servo/main.rs b/ports/servo/main.rs index 6534aed75c0..dc0ae0329aa 100644 --- a/ports/servo/main.rs +++ b/ports/servo/main.rs @@ -15,7 +15,7 @@ //! //! [glutin]: https://github.com/tomaka/glutin -#![feature(start)] +#![feature(start, core_intrinsics)] #[cfg(target_os = "android")] extern crate android_injected_glue; @@ -58,7 +58,7 @@ pub mod platform { fn install_crash_handler() { use backtrace::Backtrace; use sig::ffi::Sig; - use std::process::abort; + use std::intrinsics::abort; use std::thread; fn handler(_sig: i32) { @@ -67,7 +67,9 @@ fn install_crash_handler() { .map(|n| format!(" for thread \"{}\"", n)) .unwrap_or("".to_owned()); println!("Stack trace{}\n{:?}", name, Backtrace::new()); - abort(); + unsafe { + abort(); + } } signal!(Sig::SEGV, handler); // handle segfaults