You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I run into problems when using hwinfo and my GUI app which uses Qt6/Windows11.
QFileDialog::getOpenFileName and other functions did not work correctly (native was not working) after a call to the hwinfo lib.
I found that the CoInitializeEx in the wmi_wrapper caused the problem, after changing from COINIT_MULTITHREADED to COINIT_APARTMENTTHREADED all seamed to work well:
hwinfo/src/windows/utils/wmi_wrapper.cpp, line 16
_WMI::_WMI() {
auto res = CoInitializeSecurity(nullptr, -1, nullptr, nullptr, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE,
nullptr, EOAC_NONE, nullptr);
// res &= CoInitializeEx(nullptr, COINIT_MULTITHREADED); // $fixme: this is causing a crash
res &= CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
The text was updated successfully, but these errors were encountered:
I run into problems when using hwinfo and my GUI app which uses Qt6/Windows11.
QFileDialog::getOpenFileName and other functions did not work correctly (native was not working) after a call to the hwinfo lib.
I found that the CoInitializeEx in the wmi_wrapper caused the problem, after changing from COINIT_MULTITHREADED to COINIT_APARTMENTTHREADED all seamed to work well:
hwinfo/src/windows/utils/wmi_wrapper.cpp, line 16
_WMI::_WMI() {
auto res = CoInitializeSecurity(nullptr, -1, nullptr, nullptr, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE,
nullptr, EOAC_NONE, nullptr);
// res &= CoInitializeEx(nullptr, COINIT_MULTITHREADED); // $fixme: this is causing a crash
res &= CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
The text was updated successfully, but these errors were encountered: