[Lazarus] How do you get a report of unfreed objects in Lazarus after a program runs?

Marcos Douglas md at delfire.net
Tue Dec 13 19:21:08 CET 2011


2011/12/13 Frank Church <vfclists at gmail.com>:
>
>
> On 13 December 2011 17:10, Marcos Douglas <md at delfire.net> wrote:
>>
>> 2011/12/13 Frank Church <vfclists at gmail.com>
>> >
>> > How do you get a report of unfreed objects in Lazarus?
>> >
>> > I hav read something about heaptrc and valgrind, but don't know if the
>> > latter works on Windows.
>>
>> Include heaptrc unit in your program (would be the first unit) or use
>> IDE 'Project'>'Project Options'|'Compiler
>> Options'|'Linking'<Debugging><Use Heaptrc unit>.
>> After you close your program, a message will be displayed to you.
>
> Can the output be logged to a file?

I don't know.

> I am running in both console mode and in the normal mode using forms, and
> when I exit the program a lot of text flies by.

I think I did not understand right, but I will try to answer:
Open a new console and call your program. When the program finish the
console still there.

> I am running Lazarus 0.9.30 and I remember that in 0.9.31 a dialog is show
> when the program exits. Is that dialog present in 0.9.30 with or without the
> heap trace?

I use 0.9.31 (trunk) and never use heaptrc before .31 so, I don't know
(but is very simple, just test it!)

Marcos Douglas




More information about the Lazarus mailing list