Here are 2 codes:
WinMain():
<BR>int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR CommandLine, int ShowCommand)<BR>{<BR>//================================================================================<BR>// DirectX - Something I can't make it out of...<BR>//================================================================================<BR>ID3D10Device* pD3DDevice = NULL;<BR>IDXGISwapChain* pSwapChain = NULL;<BR>ID3D10RenderTargetView* pRenderTargetView = NULL;<BR><BR> //...<BR><BR>Shutdown(&pD3DDevice, &pSwapChain, &pRenderTargetView);<BR>return (int) msg.wParam;<BR>}<BR>
Shutdown():
void Shutdown(ID3D10Device** pDevice, IDXGISwapChain** pSwapChain, ID3D10RenderTargetView** pTarget)<BR>{<BR>//TODO: Fix this problem. No return data of NULL is returned to its owner, so...<BR>if (pTarget != NULL)<BR> (*pTarget)->Release();<BR>if (pSwapChain != NULL)<BR> (*pSwapChain)->Release();<BR>if (pDevice != NULL)<BR> (*pDevice)->Release();<BR>}
In Shutdown(), the TODO marks where the memory leaks occur. I think I have done it correctly, but whenever I stop my application process, I can see clearly that in the Task Manager, there are 2 (MSBuild.exe *32) in it.
I suspected it has to do with my code. And I suspected it's from here. So, can anyone help finding it for me? If you wanted all of the codes please let me know.