|
oh,yeah, i know what do you mean, and i've changed it, so it says char tempCity[], but still im getting the same error msg.
now i have
cityNode* createNode(char tempCity[],double x, double y)
error says:
In function `createNode':
assign2.c:76: incompatible types in assignment
that's whole msg.
and line 76 is:
tempPtr->city = tempCity;
as far as i understand it, from the fscanf im reading what is in the file - string, double, double. Then im sending it to the function addIntoLinkList as (tempCity,x,y), in addIntoLInkList function im creating new node temp by sending values tempCity, x, y to createNode function.
and there i have tempPtr which allocates space for this node and sets data into it.
So im trying to assign tempCity (array of strings) into city (array of strings).
Is there something im missing?
|