mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-11-16 13:51:19 +01:00
fix(e2e): drop the unsafe block nested inside the testwin unsafe block
e2e/guest/testwin/src/main.rs had an unsafe block inside an unsafe block, which clippy -D warnings rejects (unused_unsafe). Removes the inner one without changing behaviour. Verified: Windows clippy passes.
This commit is contained in:
1 parent
2435087e2c
commit
1f1805f66e
1 file changed
+2
-2
@@ -393,8 +393,8 @@ fn main() -> windows::core::Result<()> {
|
||||
std::thread::sleep(std::time::Duration::from_secs_f64(after));
|
||||
let hwnd = HWND(HWND_RAW.load(Ordering::SeqCst) as *mut _);
|
||||
let title = wide(&new);
|
||||
// SAFETY: `title` is NUL-terminated and outlives the call.
|
||||
let _ = unsafe { SetWindowTextW(hwnd, PCWSTR(title.as_ptr())) };
|
||||
// `title` is NUL-terminated and outlives the call.
|
||||
let _ = SetWindowTextW(hwnd, PCWSTR(title.as_ptr()));
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user