use vars qw(@ISA $VERSION);
require File::Spec::Unix;
-$VERSION = '1.4_01';
+$VERSION = '3.25_02';
@ISA = qw(File::Spec::Unix);
sub canonpath {
my($self,$path) = @_;
+ return undef unless defined $path;
+
if ($path =~ m|/|) { # Fake Unix
my $pathify = $path =~ m|/\Z(?!\n)|;
$path = $self->SUPER::canonpath($path);
sub splitdir {
my($self,$dirspec) = @_;
+ my @dirs = ();
+ return @dirs if ( (!defined $dirspec) || ('' eq $dirspec) );
$dirspec =~ tr/<>/[]/; # < and > ==> [ and ]
$dirspec =~ s/\]\[\./\.\]\[/g; # ][. ==> .][
$dirspec =~ s/\[000000\.\]\[/\[/g; # [000000.][ ==> [
# [--] ==> [-.-]
$dirspec = "[$dirspec]" unless $dirspec =~ /[\[<]/; # make legal
$dirspec =~ s/^(\[|<)\./$1/;
- my(@dirs) = split /(?<!\^)\./, vmspath($dirspec);
+ @dirs = split /(?<!\^)\./, vmspath($dirspec);
$dirs[0] =~ s/^[\[<]//s; $dirs[-1] =~ s/[\]>]\Z(?!\n)//s;
@dirs;
}