![]() |
Memory Manager in Delphi 2007
Does anyone know if Delphi 2007 has it's own memory manager?
I want to check my application for memory leaks, so i wish to report all memory leaks when i close my application. Any help? PS: I know the ReportMemoryLeaksOnShutdown works for Win32 Applications in Delphi2007, but im using a VCL.NET Application. Thanks |
Re: Memory Manager in Delphi 2007
There's no such thing as a memory leak in a (fully managed) .Net application. If you're experiencing some memory issues, could you describe them?
Whenever you have created, say, 20 new objects (i.e. generation 0 is full) since the last garbage collection, the garbage collector will reclaim any unreferenced objects (slightly simplified). The only thing you can do to help the GC is to dispose every IDisposable object as soon as you don't need it anymore. |
Re: Memory Manager in Delphi 2007
Zitat:
mmm ok, so if i do the following:
Delphi-Quellcode:
in a VCL.NET Application, then that object will automaticly be disposed? So there is no need to FeeAndNil(oConn)?
procedure TForm3.FormCreate(Sender: TObject);
begin oConn := TADOConnection.Create(nil); end Thanks |
Alle Zeitangaben in WEZ +1. Es ist jetzt 22:50 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz