in reply to globbing on remote network paths

Most likely, your backslashes are interpreted in the doublequotes by Perl. Try some diagnostic messages to debug the problem:

my $path = "\\sottbuild1f\\blacksea\\daily\\oqp\\*inst.tar.gz"; print "Searching files in >>$path<<\n"; my @files = glob($path);

Also, glob isn't completely suitable for getting files in a directory because it treats spaces in the path differently from how Perl treats spaces everywhere else, because glob tries to emulate a shell. I commonly use the following code to switch glob to a sane(r) behaviour:

use File::Glob qw(bsd_glob); my @programs = glob 'C:/Program Files';

Replies are listed 'Best First'.
Re^2: globbing on remote network paths
by Limbic~Region (Chancellor) on Jun 19, 2007 at 17:15 UTC
    Corion,
    I have wondered this for sometime, but never asked. The docs for glob in recent versions indicate that it is implemented using File::Glob and the documentation indicates that File::Glob is a Perl extension for BSD glob routine. If this is the case, than shouldn't glob already be doing a bsd_glob?

    Update: I just read further down in the docs where it says: "Due to historical reasons, CORE::glob() will also split its argument on whitespace, treating it as multiple patterns, whereas bsd_glob() considers them as one pattern."

    Cheers - L~R