core/heap.c
/* Iterator accessor:
 * Has to be initialized with special_heap_iterator_start, and should be
 * called only when special_heap_iterator_hasnext() is true.
 * Sets the area boundaries in area_start and area_end.
 */
Iterator accessor:
Has to be initialized with special_heap_iterator_start, and should be
called only when special_heap_iterator_hasnext() is true.
Sets the area boundaries in area_start and area_end.
Iterator accessor : Has to be initialized with special_heap_iterator_start and should be called only when special_heap_iterator_hasnext () is true . Sets the area boundaries in area_start and area_end .
void
special_heap_iterator_next(special_heap_iterator_t *shi ,
                           app_pc *heap_start , app_pc *heap_end )
{
    special_units_t *su;
    special_heap_unit_t *u;
    ASSERT(shi != NULL);
    su = (special_units_t *) shi->heap;
    ASSERT(su != NULL);
    ASSERT_OWN_MUTEX(true, &su->lock);
    u = (special_heap_unit_t *) shi->next_unit;
    ASSERT(u != NULL);
    if (u != NULL) { 
        if (heap_start != NULL)
            *heap_start = u->start_pc;
        ASSERT(u->cur_pc <= u->end_pc);
        if (heap_end != NULL)
            *heap_end = u->cur_pc;
        shi->next_unit = (void *) u->next;
    }
}
void special_heap_iterator_next ( special_heap_iterator_t * shi , app_pc * heap_start , app_pc * heap_end ) { special_units_t * su ; special_heap_unit_t * u ; ASSERT ( shi != NULL ) ; su = ( special_units_t * ) shi -> heap ; ASSERT ( su != NULL ) ; ASSERT_OWN_MUTEX ( true , & su -> lock ) ; u = ( special_heap_unit_t * ) shi -> next_unit ; ASSERT ( u != NULL ) ; if ( u != NULL ) { if ( heap_start != NULL ) * heap_start = u -> start_pc ; ASSERT ( u -> cur_pc <= u -> end_pc ) ; if ( heap_end != NULL ) * heap_end = u -> cur_pc ; shi -> next_unit = ( void * ) u -> next ; } }
Iterator accessor:
 Has to be initialized with special_heap_iterator_start, and should be
 called only when special_heap_iterator_hasnext() is true.
Iterator accessor : Has to be initialized with special_heap_iterator_start and should be called only when special_heap_iterator_hasnext () is true .
/* IN/OUT */ /* OUT */ /* OUT */ /* caller error, but paranoid */