Add aliases for compatibility
This commit is contained in:
@@ -6,6 +6,16 @@ extern crate platform;
|
||||
|
||||
use platform::types::*;
|
||||
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn __errno() -> *mut c_int {
|
||||
&mut platform::errno
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn __errno_location() -> *mut c_int {
|
||||
__errno()
|
||||
}
|
||||
|
||||
pub const EPERM: c_int = 1; /* Operation not permitted */
|
||||
pub const ENOENT: c_int = 2; /* No such file or directory */
|
||||
pub const ESRCH: c_int = 3; /* No such process */
|
||||
|
||||
@@ -64,6 +64,11 @@ pub extern "C" fn fstat(fildes: c_int, buf: *mut platform::types::stat) -> c_int
|
||||
platform::fstat(fildes, buf)
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn __fxstat(_ver: c_int, fildes: c_int, buf: *mut platform::types::stat) -> c_int {
|
||||
fstat(fildes, buf)
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn lstat(path: *const c_char, buf: *mut platform::types::stat) -> c_int {
|
||||
platform::lstat(path, buf)
|
||||
|
||||
Reference in New Issue
Block a user