X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXCommandmode.pm;h=4dbeb863c8ba784f8ee3b264eb4e507cfc4d0e5f;hb=3196486ff0a78459e1b88b3847d255a62fd17895;hp=95039af60ef5ef477ddc77333660a246610c830a;hpb=e266b6c9d500dde73cf0025a63a8032ea1cf378d;p=spider.git diff --git a/perl/DXCommandmode.pm b/perl/DXCommandmode.pm index 95039af6..4dbeb863 100644 --- a/perl/DXCommandmode.pm +++ b/perl/DXCommandmode.pm @@ -437,8 +437,9 @@ sub run_cmd $args = "" unless defined $args; if ($cmd) { - # strip out // on command only + # strip out // and .. on command only $cmd =~ s|//|/|g; + $cmd =~ s|\.+|\.|g; my ($path, $fcmd); @@ -454,7 +455,7 @@ sub run_cmd # first expand out the entry to a command ($path, $fcmd) = search($main::localcmd, $cmd, "pl"); - ($path, $fcmd) = search($main::cmd, $cmd, "pl") if !$path || !$fcmd; + ($path, $fcmd) = search($main::cmd, $cmd, "pl") unless $path && $fcmd; if ($path && $cmd) { dbg("path: $cmd cmd: $fcmd") if isdbg('command');