We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f42bebd commit d251ce0Copy full SHA for d251ce0
src/audio/XAudio2API.cpp
@@ -187,7 +187,8 @@ const std::vector<XAudio2API::DeviceDescriptionPtr>& XAudio2API::RefreshDevices(
187
// this function must be called from the same thread as we called CoInitializeEx
188
s_devices.clear();
189
190
- if (FAILED(CoInitializeEx(nullptr, COINIT_MULTITHREADED | COINIT_DISABLE_OLE1DDE)))
+ HRESULT r = CoInitializeEx(nullptr, COINIT_MULTITHREADED | COINIT_DISABLE_OLE1DDE);
191
+ if (r != RPC_E_CHANGED_MODE && FAILED(r))
192
return s_devices;
193
194
try
0 commit comments