
- Forum
- Programming Talk
- C and C++
- Best Alternative
Best Alternative
This is a discussion on Best Alternative within the C and C++ forums, part of the Programming Talk category; Can someone suggest the best possible way to release of all resources once a program is completed or also after ...
-
Best Alternative
Can someone suggest the best possible way to release of all resources once a program is completed or also after forcing a program for termination? I want to know the best alternative for achieving this and also kindly state the reason why it is best
-
07-10-2007, 06:44 AM #2
- Join Date
- May 2007
- Answers
- 12
the best possible way to release of all resources depends upon the programmer how he/she writes the code.
the best possible way is to make a funcion for the same purpose and make a call to free() function for any resources allocated by every pointer used in the program and as for as the other variables are concerned; all of them are destroyed by the OS itself once the program is finished.

Reply With Quote





