From c2c62cc8a4c275c59eb972da9bbe8270849e0b24 Mon Sep 17 00:00:00 2001 From: Luca Pizzamiglio Date: Sun, 21 Jul 2019 17:55:11 +0200 Subject: [PATCH] Add EINTEGRITY errno and fix style --- src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs b/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs index c0191695..464744d1 100644 --- a/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs +++ b/src/unix/bsd/freebsdlike/freebsd/freebsd12/mod.rs @@ -190,10 +190,14 @@ cfg_if! { } } -#[cfg(not(freebsd13))] -pub const ELAST: ::c_int = 96; -#[cfg(freebsd13)] -pub const ELAST: ::c_int = 97; +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 { pub fn setgrent();