[lazarus] FindInFiles.diff

Vincent Snijders vslist at zonnet.nl
Sun Aug 3 16:56:45 EDT 2003


On Sun, 03 Aug 2003 14:47:00 -0400
Bob Wingard <bwingard at gt.rr.com> wrote:

> Extends InputHistory class to include Find In Files Dialog Search
> Paths and Masks
> Modify UnitEditor To load and save Find In Files Dialog History.
> 
> Bob
I am very fond of the findinfiles dialog (and heaptrc). Some more
remarks, hopefully helpful.

The msgview form doesn't free the DirectoryList. Attached patch solves
thie memoryleak.

I think that the FindClose should be outside the if then block in de
FindMatchingFiles procedure in ideproc. What happens if FindFirst return
0, for example when there are no *.inc files in a directory. FindClose
is not called. This is also true for the recursive find, but there
FindFirst (almost?) never return zero, for a directory contains
the . file. Notice that the check if a file is a directory
      if ((faDirectory and FileInfo.Attr)>0) then (line 2104)
is only done for the first file found. Maybe this should be put inside
the repeat until loop.

Regards,
Vincent.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gz00030.gz
Type: application/octet-stream
Size: 448 bytes
Desc: "msgview.patch.gz"
Url : http://localhost/pipermail/lazarus/attachments/20030803/8b949cac/gz00030.obj


More information about the Lazarus mailing list