Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b8ef96e

Browse files
committed
[Finder] fixed regression in the Finder component (it was possible to use it without using exec before, closes #6357)
1 parent 5381fae commit b8ef96e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Symfony/Component/Finder/Shell/Shell.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,11 @@ public function testCommand($command)
5252
{
5353
if (self::TYPE_WINDOWS === $this->type) {
5454
// todo: find a way to test if windows command exists
55-
return true;
55+
return false;
56+
}
57+
58+
if (!function_exists('exec')) {
59+
return false;
5660
}
5761

5862
// todo: find a better way (command could not be available)

0 commit comments

Comments
 (0)