c# mobile memory leak 程序终止后 RRS feed

  • Question

  • 有没有可能程序终止后, 之前分配给程序的内存,资源没有回收完毕.
    目前我有这样一个现象, 每次程序运行一次, 就发现手机剩余的内存少了些. 程序关闭后和程序运行前相比.
    Monday, October 26, 2009 4:59 AM


  • What you are seeing is normal behaviour.

    You will want to look for information on WM_HIBERNATE. When your device's free memory falls below a certain level the operating system sends out a WM_HIBERNATE message. This tells applications to free up memory if they can.  If not enough programs free up memory to resolve the low memory condition then the operating system will begin to close programs until a sufficient amount of memory is free.
    Joel Ivory Johnson
    It takes all the running you can do to stay in one place.If you want to get somewhere else,you must try to run at least twice as fast as that.
    • Marked as answer by warrentang Friday, October 30, 2009 3:01 AM
    Monday, October 26, 2009 6:51 PM