version 1.4.20.3, 2013/08/22 08:48:08
|
version 1.5.4.2, 2013/11/14 14:12:28
|
Line 409 ait_clrVars(array_t * __restrict vars)
|
Line 409 ait_clrVars(array_t * __restrict vars)
|
void |
void |
ait_freeVars(array_t ** __restrict vars) |
ait_freeVars(array_t ** __restrict vars) |
{ |
{ |
|
register int i; |
|
ait_val_t *v; |
|
|
if (!vars || !*vars) |
if (!vars || !*vars) |
return; |
return; |
|
|
ait_clrVars(*vars); | for (i = 0; i < array_Size(*vars); i++) |
array_Free(*vars); | if ((v = array(*vars, i, ait_val_t*))) { |
| /* free memory if isn't zero copy */ |
| if (!AIT_IN(v)) { |
| AIT_FREE_VAL(v); |
| if ((*vars)->arr_data[i]) |
| e_free((*vars)->arr_data[i]); |
| } else |
| AIT_FREE_VAL(v); |
| (*vars)->arr_data[i] = NULL; |
| } |
| (*vars)->arr_last = -1; |
| |
array_Destroy(vars); |
array_Destroy(vars); |
} |
} |
|
|