summaryrefslogtreecommitdiff
path: root/lib/FindBin.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/FindBin.pm')
-rw-r--r--lib/FindBin.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/FindBin.pm b/lib/FindBin.pm
index 5d4c575cbc..91958a8050 100644
--- a/lib/FindBin.pm
+++ b/lib/FindBin.pm
@@ -107,15 +107,15 @@ BEGIN
}
else
{
- my $IsWin32 = $^O eq 'MSWin32';
- unless(($script =~ m#/# || ($IsWin32 && $script =~ m#\\#))
+ my $doshish = ($^O eq 'MSWin32' or $^O eq 'os2');
+ unless(($script =~ m#/# || ($dosish && $script =~ m#\\#))
&& -f $script)
{
my $dir;
foreach $dir (File::Spec->path)
{
my $scr = File::Spec->catfile($dir, $script);
- if(-r $scr && (!$IsWin32 || -x _))
+ if(-r $scr && (!$dosish || -x _))
{
$script = $scr;