From ed521850af98c76698316c4aa20676973e1f9afa Mon Sep 17 00:00:00 2001 From: David Sherret Date: Mon, 7 Nov 2022 21:40:20 -0500 Subject: chore: fix windows-only clippy error (#16560) --- runtime/ops/os/sys_info.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'runtime') diff --git a/runtime/ops/os/sys_info.rs b/runtime/ops/os/sys_info.rs index f4bc6a9c6..40de7cc4b 100644 --- a/runtime/ops/os/sys_info.rs +++ b/runtime/ops/os/sys_info.rs @@ -146,6 +146,7 @@ pub fn hostname() -> String { let mut name: Vec = vec![0u16; namelen]; // Start winsock to make `GetHostNameW` work correctly // https://github.com/retep998/winapi-rs/issues/296 + // SAFETY: winapi call WINSOCKET_INIT.call_once(|| unsafe { let mut data = mem::zeroed(); let wsa_startup_result = WSAStartup(MAKEWORD(2, 2), &mut data); -- cgit v1.2.3