The Xbase++ Programmer
POSSIBLE MEMORY LEAK
Home
Articles
Source Code
Tools
Xbase++ FAQs
  Arrays
  • Array Sorting

  •   FAQs
  • FAQ Pages
  • How to Submit
  • More FAQs to come

  •   OOP
  • Possible Memory Leak

  • Links
    Title: Possible Memory Leak
    Version: 1.0
    Author: Michael McVicker
    Date: 11/18/2008
    More Information
        Manually Destroyed Objects
    Some Objects require the programmer to specifically Destroy them.

    Obviously, when your application ends, all memory related to it and reserved for it should be released.

    However, during normal the process of creating, displaying and destroying Windows, Dialogs and the various components that make up your application, not all objects are automatically released.

    Because of the Parent/Child relationship most objects are destroyed when the parent processes the ::Destroy() method. The problem arises when an object is not part of a destroyable parent.

    Certain objects require the programmer to take care to clean things up manually.

    If you use any of the following, you MUST explicitly destroy them when you are done using them.

    XbpBitmap()
    XbpClipBoard()
    XbpFileDev()
    XbpFont()
    XbpMetaFile()
    XbpPrinter()
    XbpPresSpace()

    See the Xbase++ Class Hierarchy for more information:




     

     

     

     
     
    Helping you get more out of the Xbase++ language.
    For more information or to contribute, please contact:Support@XbaseProgrammer.com