Skip to content

Commit d5a0b33

Browse files
committed
Alphabetize target_os cfgs
1 parent 580a099 commit d5a0b33

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/unistd.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -943,12 +943,12 @@ pub fn setgid(gid: Gid) -> Result<()> {
943943

944944
pub fn setgroups(groups: &[Gid]) -> Result<()> {
945945
cfg_if! {
946-
if #[cfg(any(target_os = "macos",
947-
target_os = "ios",
946+
if #[cfg(any(target_os = "dragonfly",
948947
target_os = "freebsd",
949-
target_os = "dragonfly",
950-
target_os = "openbsd",
951-
target_os = "netbsd"))] {
948+
target_os = "ios",
949+
target_os = "macos",
950+
target_os = "netbsd",
951+
target_os = "openbsd"))] {
952952
type setgroups_ngroups_t = c_int;
953953
} else {
954954
type setgroups_ngroups_t = size_t;
@@ -960,10 +960,10 @@ pub fn setgroups(groups: &[Gid]) -> Result<()> {
960960
Errno::result(res).map(drop)
961961
}
962962

963-
#[cfg(any(target_os = "linux", target_os = "android", target_os = "macos", target_os = "ios"))]
963+
#[cfg(any(target_os = "android", target_os = "ios", target_os = "linux", target_os = "macos"))]
964964
pub fn initgroups(user: &CString, group: Gid) -> Result<()> {
965965
cfg_if! {
966-
if #[cfg(any(target_os = "macos", target_os = "ios"))] {
966+
if #[cfg(any(target_os = "ios", target_os = "macos"))] {
967967
type initgroups_group_t = c_int;
968968
} else {
969969
type initgroups_group_t = gid_t;

0 commit comments

Comments
 (0)