- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have this windows app which creates an EnhMetafile which it uses in request to the WM_PAINT message via a call to PlayEnhMetafile().
My problem is, on winNT and 2000 it works OK, however on win9x systemresources are gobbled up just by hiding and raising the window.
What might be the problem?
/Bjorn
My problem is, on winNT and 2000 it works OK, however on win9x systemresources are gobbled up just by hiding and raising the window.
What might be the problem?
/Bjorn
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Windows 9x and NT GDIs work quite differently, one of differences being total available limit for resources (IIRC only 64K on 9x, much more on NT). That, however, does not change the fact that you have resource leaks in your metafile. My guess is that you don't DeleteObjects properly (at all?) when creating metafile -- that failure "passes through" PlayEnhMetaFile. You must DeleteObject for all GDI objects you create at the end.
www.systeminternals.com has useful tools to detect memory leaks. I think latest version of Process Explorer can do it (I'm not sure, but check other tools).
www.systeminternals.com has useful tools to detect memory leaks. I think latest version of Process Explorer can do it (I'm not sure, but check other tools).
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page