i wont write the code as it is too big i will just explain lol
so i define a struct, create a pointer (will call him e) of that struct type, do a malloc with size of 1 struct (just for him to have a address), then i send the pointer in a function.
In the function i realloc e (as now i know what size it as to be) create variables, i copy those variables into e. Inside the function e have all the camps ok. when i leave the function, its all messed up.
What is the problem? does he free the space i realloced in the function when i leave it? since the variables are freed and i entered with a pointer, e then points into free memory instead of the variables?
Well i cant figure it out :S nor how to conturn this lol
i hope i wasnt too vague