Exforsys
+ Reply to Thread
Results 1 to 2 of 2

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 ...

  1. #1
    Angela is offline Member Array
    Join Date
    Apr 2006
    Answers
    85

    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


  2. #2
    Mukhtar Ahmad is offline Junior Member Array
    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.


Latest Article

Network Security Risk Assessment and Measurement

Read More...