Any idea why is this happening here?
float *image;
long size_img=par->N*par->M;
image = calloc(size_img, sizeof(float));//the compiler shows error here
The error is
error: a value of type "void *" cannot be assigned to an entity of type "float *"
Should I do a cast? The bogus thing is that I do the same elsewhere on the program and that error is not shown.
I have this as part of a struct I named par
long *tbegin;
and then I do
par->tbegin = calloc( SUMA_J, sizeof ( long ) );
And I get no error.