#ifdef _DEBUG CMemoryState oldMemState, newMemState, diffMemState; oldMemState.Checkpoint(); #endif //put method to check in here #ifdef _DEBUG newMemState.Checkpoint(); if( diffMemState.Difference( oldMemState, newMemState ) ) { TRACE("Memory leaked!\n" ); AfxMessageBox(L"Memory leaked!\n" ); } #endif
diffstate.DumpStatistics();
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)