From 3c4b18f39e06a09a05a13476f212d4deaa1e4707 Mon Sep 17 00:00:00 2001 From: wangzhengquan <wangzhengquan85@126.com> Date: 星期日, 23 八月 2020 13:10:15 +0800 Subject: [PATCH] Merge branch 'master' of https://shmqueue --- src/queue/include/shm_allocator.h | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/queue/include/shm_allocator.h b/src/queue/include/shm_allocator.h index ae94a9c..084a678 100644 --- a/src/queue/include/shm_allocator.h +++ b/src/queue/include/shm_allocator.h @@ -66,11 +66,13 @@ class SHM_Allocator { public: static void *allocate (size_t size) { - return mem_pool_malloc(size); + return mm_malloc(size); + // return mem_pool_malloc(size); } static void deallocate (void *ptr) { - return mem_pool_free(ptr); + return mm_free(ptr); + // return mem_pool_free(ptr); } }; @@ -93,6 +95,6 @@ -typedef std::basic_string<char, std::char_traits<char>, SHM_STL_Allocator<char> > shmstring; +typedef std::basic_string<char, std::char_traits<char>, SHM_STL_Allocator<char> > SHMString; #endif \ No newline at end of file -- Gitblit v1.8.0