in reply to Re: Re: Re: filtering file names to be added to an array...maybe.
in thread filtering file names to be added to an array...maybe.

There is a small issue with glob between Win32 and *nix. Consider a directory that contains files named "uc.DAT" and "lc.dat". Let's use this code to glob all files with an extension of dat on a linux box and a Win98 box (I don't have an NT box handy so YMMV).

#!/usr/bin/perl -w use strict; use Data::Dumper; my @files = glob('*.dat'); print Dumper(\@files);
Running this on linux yields this output:

$VAR1 = [ 'lc.dat' ];
On Windows 98, you get the following:

$VAR1 = [ 'lc.dat', 'uc.DAT' ];

The problem here is that Windows is case insensitive, but case preserving. This could be a potential problem if you are expecting the same output from glob on both platforms.

----
Coyote