Hello everybody,
Can you help me with this (I know there are very good C programmers here):

FILE *stream;
        int inputArraySize;
        int *inputLengthArray;
        int *inputDirectionArray;
        
        stream = fopen("db.txt","rt");
        
        fscanf(stream, "%d\n", &inputArraySize);

// this is line 24      
        inputLengthArray = calloc(inputArraySize, sizeof(int));
// this is line 25
        inputDirectionArray = calloc(inputArraySize, sizeof(int));
        
        fclose(stream);

The compiler (GCC) reports the following warnings:
24: warning: assignment makes pointer from integer without a cast
25: warning: assignment makes pointer from integer without a cast

What is wrong with my code?

Thank you.

Shae
--
Philippine Linux Users' Group (PLUG) Mailing List
[email protected] (#PLUG @ irc.free.net.ph)
Official Website: http://plug.linux.org.ph
Searchable Archives: http://marc.free.net.ph
.
To leave, go to http://lists.q-linux.com/mailman/listinfo/plug
.
Are you a Linux newbie? To join the newbie list, go to
http://lists.q-linux.com/mailman/listinfo/ph-linux-newbie

Reply via email to