I just discovered this useful piece of code for all who don’t have (including me) any memory leaks tracking code or software.
I know there are other and better solution but this can be handy for quick findings without much hassle.

First place this code in your entry point file, generally main.cpp inside your main() function


#ifdef _DEBUG
	int flag = _CrtSetDbgFlag(_CRTDBG_REPORT_FLAG);
	flag |= _CRTDBG_LEAK_CHECK_DF; // Turn on leak-checking bit
	_CrtSetDbgFlag(flag);
#endif

Now just run you game/program as you would normally, in debug mode of course.

After you close it you’ll get a nice log in the output window like this one:

See those numbers before each memory leak between brackets? Grab one of those and add this line right before the #endif


...
      _CrtSetDbgFlag(flag);
      _CrtSetBreakAlloc(689); // Comment or un-comment on need basis
#endif

Now run the game again, you shall get a break-point where the {689} memory leak happened.

I hope this is the correct way to use it, if not, let me know.