You forgot to show us the actual warning messages, which is not a good
idea if you expect us to help you deciphering them. But I think it's
clear nevertheless: something about implicit declaration of function
malloc, in:
> map = (int *) malloc((width * height * sizeof(int))); <<-- Warning here
> props = (int *) malloc((width * height * sizeof(int)));
The reason: you forgot to #include <stdlib.h>. That's the general rule
with 'implicit declaration' warnings that don't turn into 'unresolved
reference' errors at link time: you forgot to #include the header file
that declares the function the warning tells you about. If you also
get the unresolved reference error, you more likely just mistyped the
function's name.
And don't cast the return value of malloc(), in a C program. It serves
no useful purpose, but may hide bugs.
--
Hans-Bernhard Broeker (bro...@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.