1
1
mirror of https://github.com/wez/wezterm.git synced 2024-09-11 14:25:57 +03:00

filedescriptor: macos: mem::uninitialized -> MaybeUninit

Move away from the deprecated way of doing this.
This commit is contained in:
Wez Furlong 2020-01-26 19:07:19 -08:00
parent c778307b0e
commit 8c6819ef63

View File

@ -384,7 +384,7 @@ mod macos {
impl FdSet { impl FdSet {
pub fn new() -> Self { pub fn new() -> Self {
unsafe { unsafe {
let mut set = std::mem::uninitialized(); let mut set = std::mem::MaybeUninit::uninit().assume_init();
FD_ZERO(&mut set); FD_ZERO(&mut set);
Self { set } Self { set }
} }