Search Results - CodeGuru Forums
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: OReubens

Search: Search took 0.32 seconds.

  1. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    the principle of RAII is that your destructors get called, so yes "it will handle it perfectly".

    but there a couple special cases like the circular reference you mentioned where some "smart...
  2. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    And that is my precise point...
    you may leak resources other than memory, because the OS does not clean up EVERYTHING when your exe terminates. delete does more than just clean up memory, it...
  3. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    1) It's bad advice to suggest delete isn't needed. especially to novice users which might take that as a carte blanche to apply it liberally.
    2) as I said, yes, windows will clean up the memory....
  4. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    smart pointers and other forms of RAII are proper cleanup. The destructor is called and memory is properly cleaned up by the application.

    Your 'advice' was to not bother at all and let the OS...
  5. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    Sorry, but that's horrible advice. (even just on it's own).
    cleanup what you create. period. There is no good excuse for anything else.


    It could even be disastrous depending on what the...
  6. Replies
    12
    Views
    3,220

    Re: Best way to allocate large memory

    A typical application on Win32 has at best 2Gb at it's disposal.
    In practice you have considerably less than that because part of that 2Gb of memory is being used for various other stuff that gets...
Results 1 to 6 of 6


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This a Codeguru.com survey!


On-Demand Webinars (sponsored)