aboutsummaryrefslogtreecommitdiff
path: root/src/common/Debugging/WheatyExceptionReport.cpp
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2023-11-19 21:22:09 +0100
committerShauren <shauren.trinity@gmail.com>2023-11-19 21:22:40 +0100
commit8b73bb509e631ae1d8c1009479aaf8cf82db5236 (patch)
tree6d4e64c4bde1546d58d8f08543e6c2e608660264 /src/common/Debugging/WheatyExceptionReport.cpp
parent33bc42b6462aec38097430482dae1f0abb937a3d (diff)
Core/CrashHandler: Add a timeout to retrieving windows version from WMI
(cherry picked from commit 36a64884054f0bf34e815b62157be61c3476127a)
Diffstat (limited to 'src/common/Debugging/WheatyExceptionReport.cpp')
-rw-r--r--src/common/Debugging/WheatyExceptionReport.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/common/Debugging/WheatyExceptionReport.cpp b/src/common/Debugging/WheatyExceptionReport.cpp
index 52bfe739a2d..e0b0bd105de 100644
--- a/src/common/Debugging/WheatyExceptionReport.cpp
+++ b/src/common/Debugging/WheatyExceptionReport.cpp
@@ -459,14 +459,14 @@ BOOL WheatyExceptionReport::_GetWindowsVersionFromWMI(TCHAR* szVersion, DWORD cn
{
IWbemServices* tmp = nullptr;
HRESULT hres = loc->ConnectServer(
- bstr_t(L"ROOT\\CIMV2"), // Object path of WMI namespace
- nullptr, // User name. NULL = current user
- nullptr, // User password. NULL = current
- nullptr, // Locale. NULL indicates current
- 0, // Security flags.
- nullptr, // Authority (for example, Kerberos)
- nullptr, // Context object
- &tmp // pointer to IWbemServices proxy
+ bstr_t(L"ROOT\\CIMV2"), // Object path of WMI namespace
+ nullptr, // User name. NULL = current user
+ nullptr, // User password. NULL = current
+ nullptr, // Locale. NULL indicates current
+ WBEM_FLAG_CONNECT_USE_MAX_WAIT, // Security flags.
+ nullptr, // Authority (for example, Kerberos)
+ nullptr, // Context object
+ &tmp // pointer to IWbemServices proxy
);
if (FAILED(hres))