This site is no longer active and is available for archival purposes only. Registration and login is disabled.

Do I need to manually release all resources?


Do I need to manually release all resources?

Postby Nomad » Nov 6, 2006 @ 4:30pm

Do I need to manually release all resources at the end of the program by calling apropriate free() method of every object?

Or this is done automatically?
Nomad
pm Member
 
Posts: 76
Joined: Oct 28, 2006 @ 8:21pm
Location: Ukraine, Kiev


Postby Matias » Nov 6, 2006 @ 6:36pm

Nomad,

It is not necessary to call the apropiate free method when you program finishes. It's a good practice but the truth is that when the process ends, all the memory allocated for that process it`s liberated.
You don`t have to concern about this memory usage because the SO handles it. But, ONLY IF YOUR PROGRAM ENDS, if not, this memory will not be free until you call the method.

I hope it`s usefull

Best Regards
Matias Saguir - GledPlay Lead Developer
User avatar
Matias
pm Member
 
Posts: 20
Joined: Oct 11, 2006 @ 9:57pm


Postby Nomad » Nov 6, 2006 @ 10:35pm

Hi, Matias!

Yes, it was helpful.

And I want to know some more on this topic.
Is that actions that do free() method, done in every object's destructor or not?
Nomad
pm Member
 
Posts: 76
Joined: Oct 28, 2006 @ 8:21pm
Location: Ukraine, Kiev


Postby Sergio » Nov 6, 2006 @ 11:05pm

Sergio Fierens

User avatar
Sergio
pm Member
 
Posts: 97
Joined: Mar 17, 2006 @ 2:43pm


Return to GledPlay


Sort


Forum Description

Game Engine for Embedded Devices. Simple, complete, and powerful. Focused on the game.

Moderators:

Matias, Sergio

Forum permissions

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

cron