[Lazarus] GetAllFilesMask / AllFilesMask
Juha Manninen
juha.manninen62 at gmail.com
Mon Apr 22 20:58:48 CEST 2013
On 4/22/13, Bart <bartjunk64 at gmail.com> wrote:
> On Windows using '*' as filemask will find (FindFirst/FindNext) all
> files, with or without extension.
So does *.* on Windows. That is why the TFileSearcher behavior was changed.
> The problem with TFileSearcher is in the MatchesMask function.
> This interprets '*.*' as _must_ have a period.
> So it will return false on 'foo' , but true on 'foo.'
>
> On Windows, if you use MatchesMask you must remove a dangling '.*'
> from the mask, if you want to use it for filenames.
Fortunately it is a rare situation. If needed, test for it can be added.
Juha
More information about the Lazarus
mailing list