mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-23 16:54:03 +02:00
Remove an unnecessary COM initialization routine.
This commit is contained in:
-18
@@ -7718,8 +7718,6 @@ struct ma_context
|
|||||||
ma_proc RegOpenKeyExA;
|
ma_proc RegOpenKeyExA;
|
||||||
ma_proc RegCloseKey;
|
ma_proc RegCloseKey;
|
||||||
ma_proc RegQueryValueExA;
|
ma_proc RegQueryValueExA;
|
||||||
|
|
||||||
/*HRESULT*/ long CoInitializeResult;
|
|
||||||
} win32;
|
} win32;
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
@@ -44236,15 +44234,6 @@ static ma_result ma_context_uninit_backend_apis__win32(ma_context* pContext)
|
|||||||
/* For some reason UWP complains when CoUninitialize() is called. I'm just not going to call it on UWP. */
|
/* For some reason UWP complains when CoUninitialize() is called. I'm just not going to call it on UWP. */
|
||||||
#if defined(MA_WIN32_DESKTOP) || defined(MA_WIN32_GDK)
|
#if defined(MA_WIN32_DESKTOP) || defined(MA_WIN32_GDK)
|
||||||
{
|
{
|
||||||
/* TODO: Remove this once the new single threaded backend system is in place in 0.12. */
|
|
||||||
#if !defined(MA_XBOX)
|
|
||||||
{
|
|
||||||
if (pContext->win32.CoInitializeResult == S_OK || pContext->win32.CoInitializeResult == S_FALSE) {
|
|
||||||
ma_CoUninitialize(pContext); /* TODO: Remove this once the new single threaded backend system is in place in 0.12. */
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(MA_WIN32_DESKTOP)
|
#if defined(MA_WIN32_DESKTOP)
|
||||||
ma_dlclose(ma_context_get_log(pContext), pContext->win32.hUser32DLL);
|
ma_dlclose(ma_context_get_log(pContext), pContext->win32.hUser32DLL);
|
||||||
ma_dlclose(ma_context_get_log(pContext), pContext->win32.hAdvapi32DLL);
|
ma_dlclose(ma_context_get_log(pContext), pContext->win32.hAdvapi32DLL);
|
||||||
@@ -44313,13 +44302,6 @@ static ma_result ma_context_init_backend_apis__win32(ma_context* pContext)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* TODO: Remove this once the new single threaded backend system is in place in 0.12. */
|
|
||||||
#if !defined(MA_XBOX)
|
|
||||||
{
|
|
||||||
pContext->win32.CoInitializeResult = ma_CoInitializeEx(pContext, NULL, MA_COINIT_VALUE);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return MA_SUCCESS;
|
return MA_SUCCESS;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
|||||||
Reference in New Issue
Block a user