Win32Lib resource leak FIX

new topic     » topic index » view thread      » older message » newer message

I have had huge resource leak problems with two routines specially,
setWindowBackColor() and setText().
I have found that though setWindowBackColor calls deleteObject() to
delete the previous brush, if you look at deleteObject() documentation
it does say the object MUST have been tracked with trackObject().
...
so I added trackObject() to setWindowBackColor() routine after it had
gotten a new brush, and hey presto! the resource leak stopped. The 
brush object was being deleted properly.

I notice there are other deleteObject() calls in Win32Lib which do not
"seem" to have trackObject() call associated - so maybe this is a/the 
cause of some resource leak troubles other people have been having.
Maybe.

Andy Drummond.

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu