提交 91611fc3 编写于 作者: E Ed Schouten

Let libpanic_abort call into libc's abort() on CloudABI.

Ideally, we should make use of CloudABI's internal proc_raise(SIGABRT)
system call. POSIX abort() requires things like flushing of stdios,
which may not be what we want under panic conditions. Invoking the raw
CloudABI system call would have prevented that.

Unfortunately, we have to make use of the "cloudabi" crate to invoke raw
CloudABI system calls. This is undesired, as discussed in the pull
request (#47190).
上级 9a8f0a8c
......@@ -53,7 +53,7 @@
pub unsafe extern fn __rust_start_panic(_data: usize, _vtable: usize) -> u32 {
abort();
#[cfg(unix)]
#[cfg(any(unix, target_os = "cloudabi"))]
unsafe fn abort() -> ! {
extern crate libc;
libc::abort();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册