10000 Merge branch '2.0' into 2.1 · symfony/symfony@6fb7904 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6fb7904

Browse files
committed
Merge branch '2.0' into 2.1
* 2.0: [Process] Fix regression introduced in #6620 / 880da01, fixes #7082
2 parents 75c6194 + 06e6c10 commit 6fb7904

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Symfony/Component/Process/Process.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,10 @@ public function __construct($commandline, $cwd = null, array $env = null, $stdin
128128

129129
$this->commandline = $commandline;
130130
$this->cwd = $cwd;
131+
// on windows, if the cwd changed via chdir(), proc_open defaults to the dir where php was started
132+
if (null === $this->cwd && defined('PHP_WINDOWS_VERSION_BUILD')) {
133+
$this->cwd = getcwd();
134+
}
131135
if (null !== $env) {
132136
$this->env = array();
133137
foreach ($env as $key => $value) {

0 commit comments

Comments
 (0)
0