diff --git a/Cargo.toml b/Cargo.toml index 4e201d4..fc6b2c7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,8 +1,8 @@ [package] name = "wmi" -version = "0.11.1" +version = "0.11.2" authors = ["Ohad Ravid "] -edition = "2018" +edition = "2021" license = "MIT OR Apache-2.0" readme = "README.md" documentation = "https://docs.rs/crate/wmi" diff --git a/src/connection.rs b/src/connection.rs index 9391258..2a58f54 100644 --- a/src/connection.rs +++ b/src/connection.rs @@ -17,7 +17,10 @@ use winapi::{ combaseapi::{CoCreateInstance, CoInitializeEx, CoInitializeSecurity, CoSetProxyBlanket}, objbase::COINIT_MULTITHREADED, objidl::EOAC_NONE, - wbemcli::{CLSID_WbemLocator, IID_IWbemLocator, IWbemLocator, IWbemServices}, + wbemcli::{ + CLSID_WbemLocator, IID_IWbemLocator, IWbemLocator, IWbemServices, + WBEM_FLAG_CONNECT_USE_MAX_WAIT, + }, }, }; @@ -200,7 +203,7 @@ impl WMIConnection { ptr::null_mut(), ptr::null_mut(), ptr::null_mut(), - 0, + WBEM_FLAG_CONNECT_USE_MAX_WAIT as _, ptr::null_mut(), ptr::null_mut(), &mut p_svc,