123456789101112131415161718192021 |
- //! sys/utsname implementation, following http://pubs.opengroup.org/onlinepubs/7908799/xsh/sysutsname.h.html
- use platform::{Pal, Sys};
- use platform::types::*;
- pub const UTSLENGTH: usize = 65;
- #[repr(C)]
- pub struct utsname {
- pub sysname: [c_char; UTSLENGTH],
- pub nodename: [c_char; UTSLENGTH],
- pub release: [c_char; UTSLENGTH],
- pub version: [c_char; UTSLENGTH],
- pub machine: [c_char; UTSLENGTH],
- pub domainname: [c_char; UTSLENGTH],
- }
- #[no_mangle]
- pub unsafe extern "C" fn uname(uts: *mut utsname) -> c_int {
- Sys::uname(uts)
- }
|