[fpc-pascal] Destroy vs Free: Memory Leak?

Brian Winfrey bwcode4u at gmail.com
Tue Sep 7 06:18:16 CEST 2010


I have a TestCase that has this issue.  If I call obj.Free, I am
unable to step into the Destroy method and heaptrc indicates a memory
leak.  If I call obj.Destroy everything works as expected.  Following
the call to Free -
... if (obj <> nil) then obj.Destroy;
it would seem that the object must be nil.  How can I test this?  i am
unable to step into objpas?.inc.

Thanks, Brian.



More information about the fpc-pascal mailing list