aboutsummaryrefslogtreecommitdiff
path: root/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs')
-rw-r--r--src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs27
1 files changed, 22 insertions, 5 deletions
diff --git a/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs b/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs
index ab1b8d98..6bf7f957 100644
--- a/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs
+++ b/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs
@@ -190,13 +190,30 @@ cfg_if! {
}
}
-extern {
+cfg_if! {
+ if #[cfg(not(freebsd13))] {
+ pub const ELAST: ::c_int = 96;
+ } else {
+ pub const EINTEGRITY: ::c_int = 97;
+ pub const ELAST: ::c_int = 97;
+ }
+}
+
+extern "C" {
pub fn setgrent();
- pub fn mprotect(addr: *mut ::c_void, len: ::size_t, prot: ::c_int)
- -> ::c_int;
+ pub fn mprotect(
+ addr: *mut ::c_void,
+ len: ::size_t,
+ prot: ::c_int,
+ ) -> ::c_int;
pub fn freelocale(loc: ::locale_t);
- pub fn msgrcv(msqid: ::c_int, msgp: *mut ::c_void, msgsz: ::size_t,
- msgtyp: ::c_long, msgflg: ::c_int) -> ::ssize_t;
+ pub fn msgrcv(
+ msqid: ::c_int,
+ msgp: *mut ::c_void,
+ msgsz: ::size_t,
+ msgtyp: ::c_long,
+ msgflg: ::c_int,
+ ) -> ::ssize_t;
}
cfg_if! {