From 947653f0739e2c7e64298db665a925c38d0ac657 Mon Sep 17 00:00:00 2001 From: ecyrbe Date: Sun, 1 Mar 2020 10:49:58 +0100 Subject: [PATCH] fix: import correct HANDLE --- cli/priority.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cli/priority.rs b/cli/priority.rs index 500116da930539..1c8f6300d20a01 100644 --- a/cli/priority.rs +++ b/cli/priority.rs @@ -13,7 +13,7 @@ use winapi::shared::ntdef::NULL; use winapi::um::handleapi::CloseHandle; #[cfg(windows)] use winapi::um::processthreadsapi::{ - GetCurrentProcess, GetPriorityClass, OpenProcess, SetPriorityClass, HANDLE, + GetCurrentProcess, GetPriorityClass, OpenProcess, SetPriorityClass, }; #[cfg(windows)] use winapi::um::winbase::{ @@ -22,6 +22,8 @@ use winapi::um::winbase::{ REALTIME_PRIORITY_CLASS, }; #[cfg(windows)] +use winapi::um::winnt::HANDLE; +#[cfg(windows)] use winapi::um::winnt::PROCESS_QUERY_LIMITED_INFORMATION; #[cfg(target_os = "macos")] #[allow(non_camel_case_types)] @@ -133,7 +135,7 @@ mod tests { get_priority(0).expect("Should get priority"); } - #[test] + #[test] fn test_set_current_process_priority_to_low() { set_priority(0, PRIORITY_LOW).expect("Should set priority"); let priority = get_priority(0).expect("Should get priority");