Skip to content

Commit

Permalink
Auto merge of #2751 - guyru:master, r=Amanieu
Browse files Browse the repository at this point in the history
Add unix adjtime support.
  • Loading branch information
bors committed Apr 28, 2022
2 parents f6df53f + d76448f commit d31cbb1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/unix/bsd/freebsdlike/freebsd/mod.rs
Expand Up @@ -4204,7 +4204,6 @@ extern "C" {
pub fn getpagesize() -> ::c_int;
pub fn getpagesizes(pagesize: *mut ::size_t, nelem: ::c_int) -> ::c_int;

pub fn adjtime(arg1: *const ::timeval, arg2: *mut ::timeval) -> ::c_int;
pub fn clock_getcpuclockid2(arg1: ::id_t, arg2: ::c_int, arg3: *mut clockid_t) -> ::c_int;

pub fn shm_create_largepage(
Expand Down
9 changes: 9 additions & 0 deletions src/unix/mod.rs
Expand Up @@ -1389,6 +1389,15 @@ extern "C" {
pub fn getline(lineptr: *mut *mut c_char, n: *mut size_t, stream: *mut FILE) -> ssize_t;

pub fn lockf(fd: ::c_int, cmd: ::c_int, len: ::off_t) -> ::c_int;

}
cfg_if! {
if #[cfg(not(any(target_os = "emscripten",
target_os = "android")))] {
extern "C" {
pub fn adjtime(delta: *const timeval, olddelta: *mut timeval) -> ::c_int;
}
}
}

cfg_if! {
Expand Down

0 comments on commit d31cbb1

Please sign in to comment.