malloc return value cast

This commit is contained in:
rlar 2011-06-23 16:55:33 +00:00
parent 10615d5e73
commit 71a9a526cd
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2011-06-23 Robert Larice
* src/xspice/icm/spice2poly/icm_spice2poly/cfunc.mod :
malloc return value cast
2011-06-23 Robert Larice
* src/ciderlib/oned/onemesh.c ,
* src/spicelib/devices/nbjt/nbjttemp.c :

View File

@ -100,7 +100,7 @@ void spice2poly (ARGS)
if(INIT) {
Mif_Inst_Var_Data_t *p = STATIC_VAR_INST(acgains);
p -> size = num_inputs;
p -> element = malloc((size_t) num_inputs * sizeof(Mif_Value_t));
p -> element = (Mif_Value_t *) malloc((size_t) num_inputs * sizeof(Mif_Value_t));
for(i = 0; i < num_inputs; i++)
STATIC_VAR(acgains[i]) = 0.0;
}