diff --git a/tokio/src/net/unix/ucred.rs b/tokio/src/net/unix/ucred.rs index 3390819160a..bcd1c755f6a 100644 --- a/tokio/src/net/unix/ucred.rs +++ b/tokio/src/net/unix/ucred.rs @@ -39,7 +39,7 @@ impl UCred { ))] pub(crate) use self::impl_linux::get_peer_cred; -#[cfg(target_os = "netbsd")] +#[cfg(any(target_os = "netbsd", target_os = "nto"))] pub(crate) use self::impl_netbsd::get_peer_cred; #[cfg(any(target_os = "dragonfly", target_os = "freebsd"))] @@ -120,7 +120,7 @@ pub(crate) mod impl_linux { } } -#[cfg(target_os = "netbsd")] +#[cfg(any(target_os = "netbsd", target_os = "nto"))] pub(crate) mod impl_netbsd { use crate::net::unix::{self, UnixStream}; diff --git a/tokio/src/process/mod.rs b/tokio/src/process/mod.rs index 0fad67cd01a..fc661d89c1f 100644 --- a/tokio/src/process/mod.rs +++ b/tokio/src/process/mod.rs @@ -672,6 +672,8 @@ impl Command { #[cfg(unix)] #[cfg_attr(docsrs, doc(cfg(unix)))] pub fn uid(&mut self, id: u32) -> &mut Command { + #[cfg(target_os = "nto")] + let id = id as i32; self.std.uid(id); self } @@ -681,6 +683,8 @@ impl Command { #[cfg(unix)] #[cfg_attr(docsrs, doc(cfg(unix)))] pub fn gid(&mut self, id: u32) -> &mut Command { + #[cfg(target_os = "nto")] + let id = id as i32; self.std.gid(id); self }