<html><body bgcolor="#FFFFFF"><div>Re: point 5. The browsing path is used when trying to find source code files. You should put the fastmm units on the library path. </div><div><br></div><div>The project manager repeating like that is a bug that is fixed in later releases. Can't remember the cause. Just remove the entries manually. </div><div><br></div><div>I wrote a GUI frontend to the fastmm Inc file. Search my blog for how to download. It was a couple of years ago now. I actually updated it a few months ago but didn't get around to testing it fully. </div><div><br></div><div>Out of the office otherwise I'd find the link for you. </div><div><br></div><div>Cheers,</div><div>Jeremy</div><div><br>Sent from my iPhone</div><div><br>On 03/03/2010, at 7:08 AM, "John Bird" <<a href="mailto:johnkbird@paradise.net.nz">johnkbird@paradise.net.nz</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div>
<div><font color="#000000" size="2" face="Arial">I decided to try some memory leak
testing on a couple of programs to be sure all is OK, and after googling figured
that even though I have d2007 the best was to download FastMM4 from source
forge</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">This is what I figured to do to run
the tests - anyone can correct me if I am wrong:</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">1 - Add Uses FastMM in
...\Components\FastMM\FastMM4.pas as the first used unit in the .DPR
file. note I just edited the .DPR file manually.</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">2 - in the main form create add a
line</font></div>
<div><font color="#000000" size="2" face="Arial">
ReportMemoryLeaksOnShutdown := true; //#### FastMM diagnostics
if enabled</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">3 - Edit the FastMM4Options.Inc file
to set </font></div>
<div><font color="#000000" size="2" face="Arial"> get an error on
startup.}<br>{$define FullDebugMode}</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">[Note the program is a lot slower
with this in]</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">4 - Add to Project compile
options Debug Dcu's, generate debug info, local symbols,
reference info, use debug DCU's</font></div>
<div><font color="#000000" size="2" face="Arial">Add to Project link options include
TD32 debug info</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">I know not all of these are needed,
but not being sure which I just turned them all on.</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">5 - I found I had to add to each
project search path </font></div>
<div><font color="#000000" size="2" face="Arial">..\Components\FastMM
otherwise it could not find FastMM4Messages.pas or
FastMM4Messages.dcu</font></div>
<div><font color="#000000" size="2" face="Arial">even though that folder was in the
IDE global setting Tools/Options/Delphi options/Library - Win32/Browsing
Path</font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">All that done, </font><font color="#000000" size="2" face="Arial">to my relief I got a message that the only leaks
were one TFileStream, and one AnsiString</font></div><font color="#000000" size="2" face="Arial">
<div> </div>
<div>"This application has leaked memory. The small block leaks are (excluding
expected leaks registered by pointer):</div>
<div> </div>
<div>5 - 12 bytes: TFileStream x 1<br>21 - 36 bytes: AnsiString x 1</div>
<div> </div>
<div>Note: Memory leak detail is logged to a text file in the same folder as
this application. To disable this memory leak check, undefine
"EnableMemoryLeakReporting"."</div>
<div> </div>
<div>This program does open and close a lot of files with
TFileStream, (note I do all my fileopens with a library routine that
also saves a reference number, the open mode, and the filename, and so far they
all seem to be closed properly- but I am checking to be sure).<br></div>
<div>I haven't yet figured out the culprit, anyone have any hints on how to
track them down, puzzled at the Ansistring one - what does that mean, as I
thought strings do not get memory leaks, being reference counted. There
are certainly way more than one string in the project.</div>
<div> </div>
<div>Also I got a garbaged Project file - ended up with lines
like:<br></div></font>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial"> <DCCReference
Include="..\CFastMM.Pas" /><br> <DCCReference
Include="..\CoFastMM.Pas" /><br> <DCCReference
Include="..\ComFastMM.Pas" /><br> <DCCReference
Include="..\CompFastMM.Pas" /><br> <DCCReference
Include="..\CompoFastMM.Pas" /><br> <DCCReference
Include="..\ComponeFastMM.Pas" /><br> <DCCReference
Include="..\ComponeneFastMM.Pas" /><br> <DCCReference
Include="..\ComponenenFastMM.Pas" /><br> <DCCReference
Include="..\ComponenentFastMM.Pas" /><br> <DCCReference
Include="..\ComponenentsFastMM.Pas" /><br> <DCCReference
Include="..\ComponenFastMM.Pas" /><br> <DCCReference
Include="..\ComponenntsFastMM.Pas" /><br> <DCCReference
Include="..\ComponentFastMM.Pas" /><br> <DCCReference
Include="..\ComponentsFastMM.Pas" /><br> <DCCReference
Include="..\Components\FaFastMM.Pas" /><br>
<DCCReference Include="..\Components\FasFastMM.Pas"
/><br> <DCCReference
Include="..\Components\FastFastMM.Pas" /><br>
<DCCReference Include="..\Components\FastMFastMM.Pas"
/><br> <DCCReference Include="..\Components\FastMM.Pas"
/><br> <DCCReference
Include="..\Components\FastMMFastMM.Pas" /><br>
<DCCReference Include="..\Components\FastMM\FastMM.Pas"
/><br> <DCCReference
Include="..\Components\FastMM\FastMM4.Pas" />
<==== this is the right
one<br> <DCCReference Include="..\Components\FFastMM.Pas"
/><br> <DCCReference Include="..\ComponFastMM.Pas"
/><br> <DCCReference Include="..\FastMM.Pas"
/></font></div>
<div><font color="#000000" size="2" face="Arial"></font> </div>
<div><font color="#000000" size="2" face="Arial">Anyone come across this? Is it
from anything I did wrong?</font></div><font color="#000000" size="2" face="Arial">
<div><br></div></font>
<div>John</div>
</div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>NZ Borland Developers Group - Delphi mailing list</span><br><span>Post: <a href="mailto:delphi@delphi.org.nz"><a href="mailto:delphi@delphi.org.nz">delphi@delphi.org.nz</a></a></span><br><span>Admin: <a href="http://delphi.org.nz/mailman/listinfo/delphi"><a href="http://delphi.org.nz/mailman/listinfo/delphi">http://delphi.org.nz/mailman/listinfo/delphi</a></a></span><br><span>Unsubscribe: send an email to <a href="mailto:delphi-request@delphi.org.nz">delphi-request@delphi.org.nz</a> with Subject: unsubscribe</span></div></blockquote></body></html>