I need an explanation.
I have written various softwares and procedures in C. I can't understand the usage of memory. When I use a list of structs and initialize a lot of elements, sometimes I would to empty this structure to erase the memory I used.
The function FREE seems to be the only function used to deallocate memory but I believe it doesn't works correctly because I have everytime problems with memory usage.
What happens using the free function?
Is it possible that the only manner to erase a list of pointers used can be only using a procedure that for each element of the list erase all its field?
Thanks to anyone can answer