Don't register callback while still running global constructors

This commit is contained in:
baldurk
2016-07-05 19:21:21 +03:00
parent c1f4a01b1b
commit d656511d0f
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -45,14 +45,14 @@ public:
LibraryHooks::GetInstance().RegisterHook(DLL_NAME, this);
m_EnabledHooks = true;
m_InsideCreate = false;
WrappedIDXGISwapChain3::RegisterD3DDeviceCallback(GetD3D11DeviceIfAlloc);
}
bool CreateHooks(const char *libName)
{
bool success = true;
WrappedIDXGISwapChain3::RegisterD3DDeviceCallback(GetD3D11DeviceIfAlloc);
// also require d3dcompiler_??.dll
if(GetD3DCompiler() == NULL)
{
+2 -2
View File
@@ -79,14 +79,14 @@ public:
LibraryHooks::GetInstance().RegisterHook(DLL_NAME, this);
m_EnabledHooks = true;
m_InsideCreate = false;
WrappedIDXGISwapChain3::RegisterD3DDeviceCallback(GetD3D12DeviceIfAlloc);
}
bool CreateHooks(const char *libName)
{
bool success = true;
WrappedIDXGISwapChain3::RegisterD3DDeviceCallback(GetD3D12DeviceIfAlloc);
// also require d3dcompiler_??.dll
if(GetD3DCompiler() == NULL)
{