summaryrefslogtreecommitdiff
path: root/src/modules/eina
diff options
context:
space:
mode:
authorStefan Schmidt <s.schmidt@samsung.com>2013-06-14 09:56:55 +0100
committerStefan Schmidt <s.schmidt@samsung.com>2013-06-14 09:56:55 +0100
commit64c7bd14df859791522482fea6a5893b67ddc33e (patch)
treed4b25cfbff709d6e8753f49cefbe99d4541cda73 /src/modules/eina
parent16c8ab3b18a6e2ae5fd0065a5ee4c82bd0aced3b (diff)
eina/mp/one_big: Add a comment to clarify why we do not memset the complete memory.
To avoid people getting confused over this code, like myself, add a comment to clarify that only the elements need to be set to zero while the payload does not matter here.
Diffstat (limited to 'src/modules/eina')
-rw-r--r--src/modules/eina/mp/one_big/eina_one_big.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/modules/eina/mp/one_big/eina_one_big.c b/src/modules/eina/mp/one_big/eina_one_big.c
index 2fbd75915d..e658013382 100644
--- a/src/modules/eina/mp/one_big/eina_one_big.c
+++ b/src/modules/eina/mp/one_big/eina_one_big.c
@@ -125,6 +125,7 @@ eina_one_big_malloc(void *data, EINA_UNUSED unsigned int size)
125 else 125 else
126 { 126 {
127 pool->over++; 127 pool->over++;
128 /* Only need to zero list elements and not the payload here */
128 memset(mem, 0, sizeof(Eina_Inlist)); 129 memset(mem, 0, sizeof(Eina_Inlist));
129 pool->over_list = eina_inlist_append(pool->over_list, 130 pool->over_list = eina_inlist_append(pool->over_list,
130 (Eina_Inlist *)mem); 131 (Eina_Inlist *)mem);