Fix signal support
This commit is contained in:
@@ -54,6 +54,7 @@ pub const SIGPOLL: usize = SIGIO;
|
||||
pub const SIGPWR: usize = 30;
|
||||
pub const SIGSYS: usize = 31;
|
||||
pub const SIGUNUSED: usize = SIGSYS;
|
||||
pub const NSIG: usize = 32;
|
||||
|
||||
pub const SA_NOCLDSTOP: usize = 1;
|
||||
pub const SA_NOCLDWAIT: usize = 2;
|
||||
|
||||
@@ -36,7 +36,6 @@ pub struct sigaction {
|
||||
pub sa_mask: sigset_t,
|
||||
}
|
||||
|
||||
pub const NSIG: usize = 64;
|
||||
pub type sigset_t = c_ulong;
|
||||
|
||||
#[no_mangle]
|
||||
|
||||
@@ -51,6 +51,7 @@ pub const SIGWINCH: usize = 28;
|
||||
pub const SIGIO: usize = 29;
|
||||
pub const SIGPWR: usize = 30;
|
||||
pub const SIGSYS: usize = 31;
|
||||
pub const NSIG: usize = 32;
|
||||
|
||||
pub const SA_NOCLDSTOP: usize = 0x00000001;
|
||||
pub const SA_NOCLDWAIT: usize = 0x00000002;
|
||||
|
||||
@@ -53,17 +53,6 @@ pub extern "C" fn gettimeofday(tp: *mut timeval, tzp: *mut timezone) -> c_int {
|
||||
Sys::gettimeofday(tp, tzp)
|
||||
}
|
||||
|
||||
// #[no_mangle]
|
||||
pub extern "C" fn select(
|
||||
nfds: c_int,
|
||||
readfds: *mut fd_set,
|
||||
writefds: *mut fd_set,
|
||||
errorfds: *mut fd_set,
|
||||
timeout: *mut timeval,
|
||||
) -> c_int {
|
||||
unimplemented!();
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn utimes(path: *const c_char, times: *const timeval) -> c_int {
|
||||
let path = CStr::from_ptr(path);
|
||||
@@ -79,10 +68,3 @@ pub unsafe extern "C" fn utimes(path: *const c_char, times: *const timeval) -> c
|
||||
];
|
||||
Sys::utimens(path, times_spec.as_ptr())
|
||||
}
|
||||
|
||||
/*
|
||||
#[no_mangle]
|
||||
pub extern "C" fn func(args) -> c_int {
|
||||
unimplemented!();
|
||||
}
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user