summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2013-05-17 11:39:01 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2013-05-17 11:39:01 +0200
commit6667acf5a2ec29cac87d4ad6656b5e9327457b86 (patch)
tree9c756a1bc6196d79216ae3aa2c82fecc84f311b8
parentf253cfc12c27118e6516f6fec5d56922de119db8 (diff)
downloadefl-6667acf5a2ec29cac87d4ad6656b5e9327457b86.tar.gz
eo ptr ind: fix comments
-rw-r--r--src/lib/eo/eo_ptr_indirection.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/lib/eo/eo_ptr_indirection.c b/src/lib/eo/eo_ptr_indirection.c
index 4dc768b99c..3bb28c1412 100644
--- a/src/lib/eo/eo_ptr_indirection.c
+++ b/src/lib/eo/eo_ptr_indirection.c
@@ -262,7 +262,7 @@ _eo_obj_pointer_get(const Eo_Id obj_id)
EO_DECOMPOSE_ID(obj_id, mid_table_id, table_id, entry_id, generation);
- /* Checking the validity of the entry */
+ /* Check the validity of the entry */
if (_eo_ids_tables[mid_table_id] && TABLE_FROM_IDS)
{
entry = &(TABLE_FROM_IDS->entries[entry_id]);
@@ -336,9 +336,10 @@ _search_tables()
}
else
{
- /* Allocate a new one and reserve the first entry */
+ /* Allocate a new table */
table = _eo_id_mem_calloc(1, sizeof(_Eo_Ids_Table));
}
+ /* Initialize the table and reserve the first entry */
table->start = 1;
table->free_entries = MAX_ENTRY_ID - 1;
table->fifo_head = table->fifo_tail = -1;
@@ -385,7 +386,7 @@ _eo_id_allocate(const _Eo *obj)
_eo_generation_counter++;
if (_eo_generation_counter == MAX_GENERATIONS)
_eo_generation_counter = 1;
- /* An entry was found - fill it */
+ /* Fill the entry and return it's Eo Id */
entry->ptr = (_Eo *)obj;
entry->active = 1;
entry->generation = _eo_generation_counter;
@@ -408,7 +409,7 @@ _eo_id_release(const Eo_Id obj_id)
Table_Index mid_table_id, table_id, entry_id;
EO_DECOMPOSE_ID(obj_id, mid_table_id, table_id, entry_id, generation);
- /* Checking the validity of the entry */
+ /* Check the validity of the entry */
if (_eo_ids_tables[mid_table_id] && (table = TABLE_FROM_IDS))
{
entry = &(table->entries[entry_id]);