Skip to content

Commit c95d70f

Browse files
committed
unistd: groups: drop -> |_| ()
1 parent 18853a8 commit c95d70f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/unistd.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1007,7 +1007,7 @@ pub fn setgroups(groups: &[Gid]) -> Result<()> {
10071007
libc::setgroups(groups.len() as setgroups_ngroups_t, groups.as_ptr() as *const gid_t)
10081008
};
10091009

1010-
Errno::result(res).map(drop)
1010+
Errno::result(res).map(|_| ())
10111011
}
10121012

10131013
/// Calculate the supplementary group access list. Gets the group IDs of all
@@ -1090,14 +1090,14 @@ pub fn initgroups(user: &CString, group: Gid) -> Result<()> {
10901090
let gid: gid_t = group.into();
10911091
let res = unsafe { libc::initgroups(user.as_ptr(), gid as initgroups_group_t) };
10921092

1093-
Errno::result(res).map(drop)
1093+
Errno::result(res).map(|_| ())
10941094
}
10951095

10961096
#[inline]
10971097
pub fn pause() -> Result<()> {
10981098
let res = unsafe { libc::pause() };
10991099

1100-
Errno::result(res).map(drop)
1100+
Errno::result(res).map(|_| ())
11011101
}
11021102

11031103
#[inline]

0 commit comments

Comments
 (0)