Allcoating memory and not freeing it

This is a discussion on Allcoating memory and not freeing it within the C Programming forums, part of the General Programming Boards category; If I were to allocate memory but not free it. This causes a memory leak, right? Wouldn't I be able ...

  1. #1
    Registered User
    Join Date
    Aug 2001
    Posts
    380

    Allcoating memory and not freeing it

    If I were to allocate memory but not free it. This causes a memory leak, right? Wouldn't I be able to free this memory back by simply reseting my computer?

  2. #2
    Anti-Terrorist
    Join Date
    Aug 2001
    Location
    mming, Game DevelopmentCSR >&<>&2Minimization of boolean functions, PROM,PLA design >&0>&WA, USA guitar, dogsCommercial Aviation >&>>&USAProgramming
    Posts
    742
    Yes, infact as soon as the program ends all the memory if freed. The only time where you will run into a problem is if you create a program that is constantly running in the background such as a utility program on a server that stays on 24/7.

    Even so, you should always free memory allocated on the free store.
    I compile code with:
    Visual Studio.NET beta2

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21