Skip to content

Commit

Permalink
define sethostname under OpenBSD and Bitrig
Browse files Browse the repository at this point in the history
factorize the definition with NetBSD
  • Loading branch information
semarie committed Sep 16, 2016
1 parent 836cda9 commit 7adbc75
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions src/unix/bsd/netbsdlike/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -529,6 +529,7 @@ extern {
abstime: *const ::timespec) -> ::c_int;
pub fn pthread_condattr_setclock(attr: *mut pthread_condattr_t,
clock_id: clockid_t) -> ::c_int;
pub fn sethostname(name: *const ::c_char, len: ::size_t) -> ::c_int;
}

cfg_if! {
Expand Down
1 change: 0 additions & 1 deletion src/unix/bsd/netbsdlike/netbsd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,6 @@ extern {
pid: ::pid_t,
addr: *mut ::c_void,
data: ::c_int) -> ::c_int;
pub fn sethostname(name: *const ::c_char, len: ::size_t) -> ::c_int;
pub fn pthread_setname_np(t: ::pthread_t,
name: *const ::c_char,
arg: *mut ::c_void) -> ::c_int;
Expand Down

0 comments on commit 7adbc75

Please sign in to comment.