Browse Source

core/mem: set shm type when initializing shared memory pool

Daniel-Constantin Mierla 11 years ago
parent
commit
c996d5ddc9
2 changed files with 2 additions and 2 deletions
  1. 1 1
      mem/shm_mem.c
  2. 1 1
      mem/shm_mem.h

+ 1 - 1
mem/shm_mem.c

@@ -178,7 +178,7 @@ int shm_getmem(void)
 int shm_mem_init_mallocs(void* mempool, unsigned long pool_size)
 {
 	/* init it for malloc*/
-	shm_block=shm_malloc_init(mempool, pool_size);
+	shm_block=shm_malloc_init(mempool, pool_size, MEM_TYPE_SHM);
 	if (shm_block==0){
 		LOG(L_CRIT, "ERROR: shm_mem_init: could not initialize shared"
 				" malloc\n");

+ 1 - 1
mem/shm_mem.h

@@ -150,7 +150,7 @@
 #	define MY_STATUS(...) 0
 #	define MY_SUMS do{}while(0)
 #	define MY_MEMINFO	mspace_info
-#	define  shm_malloc_init(buf, len) create_mspace_with_base(buf, len, 0)
+#	define  shm_malloc_init(buf, len, type) create_mspace_with_base(buf, len, 0)
 #	define shm_malloc_destroy(b) do{}while(0)
 #	define shm_malloc_on_fork() do{}while(0)
 #else