Example #1
0
void
clear_ref_from_wiz_list (void)

/* GC support: Clear the refs for the wiz_list memory.
 */

{
    wiz_list_t *w;

    for (w = all_wiz; w; w = w->next)
    {
        clear_ref_in_vector(&w->extra, 1);
        if(w->file_name)
            clear_string_ref(w->file_name);
        if(w->error_message)
            clear_string_ref(w->error_message);
    }
    clear_ref_in_vector(&default_wizlist_entry.extra, 1);
} /* clear_ref_from_wiz_list() */
Example #2
0
void
clear_simul_efun_refs (void)

/* GC support: clear the references of all memory held by the module.
 */

{
    if (simul_efun_vector && simul_efun_vector->ref)
    {
        simul_efun_vector->ref = 0;
        clear_ref_in_vector(
          simul_efun_vector->item,
          VEC_SIZE(simul_efun_vector)
        );
    }
    if (simul_efun_program)
        simul_efun_program->ref = 0;
} /* clear_simul_efun_refs() */
Example #3
0
/*-------------------------------------------------------------------------*/
void
clear_struct_ref (struct_t * pStruct)

/* Clear all references held by struct <pStruct>
 */

{
    if (pStruct->ref != 0)
    {
        clear_memory_reference(pStruct);
        pStruct->ref = 0;
        clear_struct_type_ref(pStruct->type);
        if (struct_size(pStruct))
        {
            clear_ref_in_vector(pStruct->member, struct_size(pStruct));
        }
    }
} /* clear_struct_ref() */