Explorar el Código

[BrowserKit] fixed a weird behavior where a PHP process returns a successful exit code, but the PHP scripts actually died

Fabien Potencier hace 14 años
padre
commit
6d334289ee
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      src/Symfony/Component/BrowserKit/Client.php

+ 1 - 1
src/Symfony/Component/BrowserKit/Client.php

@@ -285,7 +285,7 @@ abstract class Client
         $process = new PhpProcess($this->getScript($request));
         $process->run();
 
-        if (!$process->isSuccessful()) {
+        if (!$process->isSuccessful() || !preg_match('/^O\:\d+\:/', $process->getOutput())) {
             throw new \RuntimeException($process->getErrorOutput());
         }