http://www.perlmonks.org?node_id=189207


in reply to Re: Re: globing files with spaces problem.
in thread globing files with spaces problem.

Change:

while (defined($sourcefile = bsd_glob("*")))

to:

foreach my $sourcefile (bsd_glob("*"))

bsd_glob doesn't act like the <*.foo> operator, as CORE::glob does.