memory leak

Started by
11 comments, last by muffinsssss 14 years, 8 months ago
Quote:Original post by Kwizatz
Edit: Actually, the VC leak detection seems to be a pain to use


// All translation units must include:#if defined( _MSC_VER )#define _CRTDBG_MAP_ALLOC#include <stdlib.h>#include <crtdbg.h>#define new DEBUG_NEW#define DEBUG_NEW new( _NORMAL_BLOCK, __FILE__, __LINE__ )#endif// And add this at main()_CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF );
Advertisement
Quote:Original post by _fastcall
Quote:Original post by Kwizatz
Edit: Actually, the VC leak detection seems to be a pain to use


*** Source Snippet Removed ***


Exactly [smile], why can't it be a compiler flag?
Problem solved, I'm just a moron.

This topic is closed to new replies.

Advertisement