diff --git a/src/public/tier0/imemalloc.h b/src/public/tier0/imemalloc.h index a33b72e9..5caa290c 100644 --- a/src/public/tier0/imemalloc.h +++ b/src/public/tier0/imemalloc.h @@ -10,6 +10,15 @@ #ifndef TIER0_IMEMALLOC_H #define TIER0_IMEMALLOC_H +inline void* MemAlloc_Alloc(size_t nSize, const char* pFileName = NULL, int nLine = 0) { return malloc(nSize); } +inline void MemAlloc_Free(void* ptr, const char* pFileName = NULL, int nLine = 0) { free(ptr); } + +inline void* MemAlloc_AllocAligned(size_t size, size_t align) { return _aligned_malloc(size, align); } +inline void* MemAlloc_AllocAlignedFileLine(size_t size, size_t align, const char* pszFile = NULL, int nLine = 0) { return _aligned_malloc(size, align); } +inline void MemAlloc_FreeAligned(void* pMemBlock, const char* pszFile = NULL, int nLine = 0) { free(pMemBlock); } + +//----------------------------------------------------------------------------- + /// This interface class is used to let the mem_dump command retrieve /// information about memory allocations outside of the heap. It is currently /// used by CMemoryStack to report on its allocations. diff --git a/src/tier1/CMakeLists.txt b/src/tier1/CMakeLists.txt index 85b75857..51a8f685 100644 --- a/src/tier1/CMakeLists.txt +++ b/src/tier1/CMakeLists.txt @@ -19,7 +19,7 @@ add_sources( SOURCE_GROUP "Utility" "utlstring.cpp" "characterset.cpp" "mempool.cpp" - #"memstack.cpp" + "memstack.cpp" ) add_sources( SOURCE_GROUP "Private"