5 #define POOL_SIZE 1024 * 10
8 // Pool size is in bytes.
17 printf("Pools' addresses: (0) %p (1) %p (2) %p (3) %p\n", p0
, p1
, p2
, p3
);
18 init_memory_pool(POOL_SIZE
, p0
);
19 add_new_area(p3
, POOL_SIZE
, p0
);
20 add_new_area(p1
, POOL_SIZE
, p0
);
21 add_new_area(p2
, POOL_SIZE
, p0
);
23 if (!(ptr
=malloc_ex(POOL_SIZE
*2, p0
))){
30 destroy_memory_pool(p0
);