// -*- C++ -*- #ifndef _MMAPALLOC_H_ #define _MMAPALLOC_H_ #include #include "mmapwrapper.h" /** * @class MmapAlloc * @brief Obtains memory from Mmap but doesn't allow it to be freed. * @author Emery Berger */ namespace Hoard { class MmapAlloc { public: void * malloc (size_t sz) { void * ptr = HL::MmapWrapper::map (sz); return ptr; } }; } #endif