summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <msvensson@neptunus.(none)>2006-08-25 10:11:15 +0200
committerunknown <msvensson@neptunus.(none)>2006-08-25 10:11:15 +0200
commit72695c3fae1281ccf535907edf847077446e971d (patch)
treef867485ddb94c90a103c8102839dfdd2eb23eb3f /mysql-test
parent4934231545c994b90517b2c1b4c9b85b4fbe2018 (diff)
downloadmariadb-git-72695c3fae1281ccf535907edf847077446e971d.tar.gz
Backport fix for finding executables from 5.0
mysql-test/lib/mtr_misc.pl: On windows the exe does not need to be executable for it to be found
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/lib/mtr_misc.pl18
1 files changed, 16 insertions, 2 deletions
diff --git a/mysql-test/lib/mtr_misc.pl b/mysql-test/lib/mtr_misc.pl
index 26d5b9ed283..08c99e90906 100644
--- a/mysql-test/lib/mtr_misc.pl
+++ b/mysql-test/lib/mtr_misc.pl
@@ -82,7 +82,14 @@ sub mtr_path_exists (@) {
sub mtr_script_exists (@) {
foreach my $path ( @_ )
{
- return $path if -x $path;
+ if($::glob_win32)
+ {
+ return $path if -f $path;
+ }
+ else
+ {
+ return $path if -x $path;
+ }
}
if ( @_ == 1 )
{
@@ -99,7 +106,14 @@ sub mtr_exe_exists (@) {
map {$_.= ".exe"} @path if $::glob_win32;
foreach my $path ( @path )
{
- return $path if -x $path;
+ if($::glob_win32)
+ {
+ return $path if -f $path;
+ }
+ else
+ {
+ return $path if -x $path;
+ }
}
if ( @path == 1 )
{