diff options
author | Kissaki <kissaki@gmx.de> | 2013-04-21 05:42:00 +0400 |
---|---|---|
committer | Kissaki <kissaki@gmx.de> | 2013-06-05 00:37:39 +0400 |
commit | bb47083b9fe36cd01f699b66a117e8d68024f85f (patch) | |
tree | 09a90f975844c16ce2bc6413f695b3966411b6df /overlay/d3d10.cpp | |
parent | 85fa2ce57a0a2159e2065855ec6e2b1e1045671e (diff) |
Reduce varscopes and improve debugtext.
Diffstat (limited to 'overlay/d3d10.cpp')
-rw-r--r-- | overlay/d3d10.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/overlay/d3d10.cpp b/overlay/d3d10.cpp index de05440e2..34e0f5ed4 100644 --- a/overlay/d3d10.cpp +++ b/overlay/d3d10.cpp @@ -37,7 +37,6 @@ DXGIData *dxgi = NULL; static bool bHooked = false; -static bool bChaining = false; static HardHook hhPresent; static HardHook hhResize; static HardHook hhAddRef; @@ -550,15 +549,16 @@ static void HookResizeRaw(voidFunc vfResize) { } void checkDXGIHook(bool preonly) { - if (bChaining) { - ods("DXGI: Causing a chain"); + static bool bCHActive = false; + if (bCHActive) { + ods("DXGI: Recursion in checkDXGIHook"); return; } if (! dxgi->iOffsetPresent || ! dxgi->iOffsetResize) return; - bChaining = true; + bCHActive = true; HMODULE hDXGI = GetModuleHandleW(L"DXGI.DLL"); HMODULE hD3D10 = GetModuleHandleW(L"D3D10CORE.DLL"); @@ -593,7 +593,7 @@ void checkDXGIHook(bool preonly) { } } - bChaining = false; + bCHActive = false; } extern "C" __declspec(dllexport) void __cdecl PrepareDXGI() { |