M
MK
I am a newbie. Please help. The following warning is issued by gcc-3.2.2
compiler (pc Linux):
==================================================================
read_raw_data.c:51: warning: assignment makes pointer from integer
without a cast
==================================================================
when the following piece of code was compiled. The offending statement
is calloc. A similar statement in the main() function passes without any
warning. Am I allowed to use calloc (and malloc) only within main() or
am I doing something very silly ??
=============================================
init(char *file, double *grid, \
double *start){
double *depth;
int pts
depth = calloc(pts,sizeof (double));
}
============================================
Thanks.
MK
compiler (pc Linux):
==================================================================
read_raw_data.c:51: warning: assignment makes pointer from integer
without a cast
==================================================================
when the following piece of code was compiled. The offending statement
is calloc. A similar statement in the main() function passes without any
warning. Am I allowed to use calloc (and malloc) only within main() or
am I doing something very silly ??
=============================================
init(char *file, double *grid, \
double *start){
double *depth;
int pts
depth = calloc(pts,sizeof (double));
}
============================================
Thanks.
MK