*polished code.

This commit is contained in:
Wang Renxin 2015-10-08 20:14:33 +08:00
parent 5f8c901094
commit 01034e6697

View File

@ -847,14 +847,13 @@ static void _on_exit(void) {
c = 0; c = 0;
#ifdef _USE_MEM_POOL #ifdef _USE_MEM_POOL
if(alloc_count > 0) {
mb_assert(0 && "Memory leak");
}
_close_mem_pool(); _close_mem_pool();
#endif /* _USE_MEM_POOL */ #endif /* _USE_MEM_POOL */
#if defined _MSC_VER && !defined _WIN64 #if defined _MSC_VER && !defined _WIN64
if(0 != _CrtDumpMemoryLeaks()) { _asm { int 3 } } if(0 != _CrtDumpMemoryLeaks()) { _asm { int 3 } }
#elif defined _USE_MEM_POOL
if(alloc_count > 0) { mb_assert(0 && "Memory leak"); }
#endif /* _MSC_VER && !_WIN64 */ #endif /* _MSC_VER && !_WIN64 */
} }