Skip to content
Snippets Groups Projects
Commit 93fc82b7 authored by Adam G-H's avatar Adam G-H
Browse files

Disable pcre.jit

parent be892d9f
No related branches found
No related tags found
No related merge requests found
...@@ -47,10 +47,16 @@ final class ProcessFactory implements ProcessFactoryInterface { ...@@ -47,10 +47,16 @@ final class ProcessFactory implements ProcessFactoryInterface {
* {@inheritdoc} * {@inheritdoc}
*/ */
public function create(array $command): Process { public function create(array $command): Process {
if ($this->isComposerCommand($command)) {
array_unshift($command, '-dpcre.jit=0');
array_unshift($command, PHP_BINARY);
$composer_command = TRUE;
}
$process = $this->decorated->create($command); $process = $this->decorated->create($command);
$env = $process->getEnv(); $env = $process->getEnv();
if ($this->isComposerCommand($command)) { if ($this->isComposerCommand($command) || isset($composer_command)) {
$env['COMPOSER_HOME'] = $this->getComposerHomePath(); $env['COMPOSER_HOME'] = $this->getComposerHomePath();
} }
// Ensure that the running PHP binary is in the PATH. // Ensure that the running PHP binary is in the PATH.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment