summaryrefslogtreecommitdiffhomepage
path: root/mullvad-paths/src
diff options
context:
space:
mode:
authorJoakim Hulthe <joakim.hulthe@mullvad.net>2025-02-11 15:13:19 +0100
committerJoakim Hulthe <joakim.hulthe@mullvad.net>2025-02-25 13:37:34 +0100
commit281018b91cd12d49af83cbfc3003b1dd08829d39 (patch)
tree6d33d00d8fa1117a3321814350ade2e2306d27f5 /mullvad-paths/src
parentf7e0f10bf99c8b73b29aa21026642b368beae1f1 (diff)
downloadmullvadvpn-281018b91cd12d49af83cbfc3003b1dd08829d39.tar.xz
mullvadvpn-281018b91cd12d49af83cbfc3003b1dd08829d39.zip
Allow undocumented_unsafe_blocks in mullvad_paths::windows
Diffstat (limited to 'mullvad-paths/src')
-rw-r--r--mullvad-paths/src/windows.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/mullvad-paths/src/windows.rs b/mullvad-paths/src/windows.rs
index 2898e76ba8..fa652f31f7 100644
--- a/mullvad-paths/src/windows.rs
+++ b/mullvad-paths/src/windows.rs
@@ -1,3 +1,5 @@
+#![allow(clippy::undocumented_unsafe_blocks)] // Remove me if you dare.
+
use crate::{Error, Result};
use once_cell::sync::OnceCell;
use std::{
@@ -362,6 +364,7 @@ fn adjust_token_privilege(
privilege: &WideCStr,
enable: bool,
) -> std::io::Result<()> {
+ // SAFETY: LUID is a C struct and can safely be zeroed.
let mut privilege_luid: LUID = unsafe { mem::zeroed() };
if unsafe { LookupPrivilegeValueW(ptr::null(), privilege.as_ptr(), &mut privilege_luid) } == 0 {