Freeing unused GDI handles

delphi package - easy access to kernel objects etc.
Post Reply
bendeguz
Posts: 2
Joined: Fri Feb 08, 2008 11:54 pm

Freeing unused GDI handles

Post by bendeguz »

I'm writing a multimedia application using DSPack and my problem is that my app crashes after some hours and in the task manager the GDI handles are around 10000. I asked about this on their forum, but they sent me here and told me that with IHandle interface I can track down this issue. It would be nice if someone could write me a pseudo-code for freeing up the unneeded handles or confirm that it is possible with madKernel. Thank you.
madshi
Site Admin
Posts: 10754
Joined: Sun Mar 21, 2004 5:25 pm

Post by madshi »

Hello,

I'm sorry to say but IHandle is for kernel handles (files, threads, processes, mutexes, events etc) and not for GDI handles (bitmaps, icons, brushes, pens etc).

If you're using Delphi you may want to try one of the leak checking algorithms. Personally I'm using MemProof (freeware).
Post Reply