com php-src: enforce the test ini usage for the child process: ext/openssl/tests/ServerClientTestCase.inc

From: Date: Sun, 04 Dec 2016 13:01:40 +0000
Subject: com php-src: enforce the test ini usage for the child process: ext/openssl/tests/ServerClientTestCase.inc
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-96180@lists.php.net to get a copy of this message
Commit: 10a2ceef3bfada85e7046231476d06f08d3de69c Author: Anatol Belski <ab@php.net> Sun, 4 Dec 2016 14:01:40 +0100 Parents: 46d708a1b655196afef875704672a9372260f1b2 Branches: PHP-7.0 PHP-7.1 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=10a2ceef3bfada85e7046231476d06f08d3de69c Log: enforce the test ini usage for the child process Changed paths: M ext/openssl/tests/ServerClientTestCase.inc Diff: diff --git a/ext/openssl/tests/ServerClientTestCase.inc b/ext/openssl/tests/ServerClientTestCase.inc index 03e0c2d...478b337 100644 --- a/ext/openssl/tests/ServerClientTestCase.inc +++ b/ext/openssl/tests/ServerClientTestCase.inc @@ -48,9 +48,13 @@ class ServerClientTestCase private function spawnWorkerProcess($code) { - $cmd = sprintf('%s "%s" %s', PHP_BINARY, __FILE__, WORKER_ARGV_VALUE); - - $this->workerHandle = proc_open($cmd, [['pipe', 'r'], ['pipe', 'w'], STDERR], $pipes); + if (defined("PHP_WINDOWS_VERSION_MAJOR")) { + $ini = php_ini_loaded_file(); + $cmd = sprintf('%s %s "%s" %s', PHP_BINARY, $ini ? "-n -c $ini" : "", __FILE__, WORKER_ARGV_VALUE); + } else { + $cmd = sprintf('%s "%s" %s', PHP_BINARY, __FILE__, WORKER_ARGV_VALUE); + } + $this->workerHandle = proc_open($cmd, [['pipe', 'r'], ['pipe', 'w'], STDERR], $pipes); $this->workerStdIn = $pipes[0]; $this->workerStdOut = $pipes[1];

« previous php.cvs (#96180) next »