Hello, I was trying to program a game with c when I realized that if anyone, who is playing in my game, close the window the memory that I reserved will still reserved int the pc. If it's not too much memory it doesen't matter but if i save all with pointers or it happens too many times it may be a problem.
My question is: Is there anyway to free the memory reserved when the program is forçed to close? and... if it's not possible can I free this memory after?
Another question it stirs in me is what hapen with the momory of the variables tahat don't need to be reserved if you force the program to close?