8000 bug #53481 [Process] Fix executable finder when the command starts wi… · symfony/symfony@f626a2c · GitHub
[go: up one dir, main page]

Skip to content

Commit f626a2c

Browse files
c 8000 ommitted
bug #53481 [Process] Fix executable finder when the command starts with a dash (kayw-geek)
This PR was submitted for the 7.1 branch but it was merged into the 5.4 branch instead. Discussion ---------- [Process] Fix executable finder when the command starts with a dash | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | Fix #53479 | License | MIT Commits ------- 8ceaa8e [Process] Fix executable finder when the command starts with a dash
2 parents fa9bf2d + 8ceaa8e commit f626a2c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Process/PhpExecutableFinder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public function find(bool $includeArgs = true)
3535
{
3636
if ($php = getenv('PHP_BINARY')) {
3737
if (!is_executable($php)) {
38-
$command = '\\' === \DIRECTORY_SEPARATOR ? 'where' : 'command -v';
38+
$command = '\\' === \DIRECTORY_SEPARATOR ? 'where' : 'command -v --';
3939
if ($php = strtok(exec($command.' '.escapeshellarg($php)), \PHP_EOL)) {
4040
if (!is_executable($php)) {
4141
return false;

0 commit comments

Comments
 (0)
0