diff options
author | Anatol Belski <ab@php.net> | 2018-05-18 17:44:48 +0200 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2018-05-18 17:44:48 +0200 |
commit | ef9922faa90c5ca7491777afdb08ecd20aa3eee9 (patch) | |
tree | 68340f2f6a3e5a0d70974c41d0d204b897265dfa /ext/curl | |
parent | a551d759427adfe9ca1876654a0c0e55c051cfa6 (diff) | |
parent | e470068293c925b3286574f51f2b93957b146145 (diff) | |
download | php-git-ef9922faa90c5ca7491777afdb08ecd20aa3eee9.tar.gz |
Merge branch 'PHP-7.2'
* PHP-7.2:
Fix curl tests wrt. AppVeyor and curl updates
Diffstat (limited to 'ext/curl')
-rw-r--r-- | ext/curl/tests/bug48203-win32.phpt | 5 | ||||
-rw-r--r-- | ext/curl/tests/bug54798-win32.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/server.inc | 18 |
3 files changed, 15 insertions, 9 deletions
diff --git a/ext/curl/tests/bug48203-win32.phpt b/ext/curl/tests/bug48203-win32.phpt index 947c33a3d1..d3affdb71d 100644 --- a/ext/curl/tests/bug48203-win32.phpt +++ b/ext/curl/tests/bug48203-win32.phpt @@ -30,7 +30,8 @@ echo "Ok\n"; <?php @unlink(dirname(__FILE__) . '/bug48203.tmp'); ?> --EXPECTF-- Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %s on line %d -Hello World! -Hello World!Ok %A +Hello World! +Hello World!* Closing connection 0 +Ok diff --git a/ext/curl/tests/bug54798-win32.phpt b/ext/curl/tests/bug54798-win32.phpt index c3b240dea7..bce39903ba 100644 --- a/ext/curl/tests/bug54798-win32.phpt +++ b/ext/curl/tests/bug54798-win32.phpt @@ -65,4 +65,3 @@ Hello World!Ok for CURLOPT_FILE %AOk for CURLOPT_INFILE ===DONE=== -%A diff --git a/ext/curl/tests/server.inc b/ext/curl/tests/server.inc index 151f189e26..124e0f898c 100644 --- a/ext/curl/tests/server.inc +++ b/ext/curl/tests/server.inc @@ -13,17 +13,23 @@ function curl_cli_server_start() { $doc_root = __DIR__; $router = "responder/get.php"; - $descriptorspec = array( - 0 => STDIN, - 1 => STDOUT, - 2 => STDERR, - ); - if (substr(PHP_OS, 0, 3) == 'WIN') { + $descriptorspec = array( + 0 => STDIN, + 1 => STDOUT, + 2 => array("pipe", "w"), + ); + $cmd = "{$php_executable} -t {$doc_root} -n -S " . PHP_CURL_SERVER_ADDRESS; $cmd .= " {$router}"; $handle = proc_open(addslashes($cmd), $descriptorspec, $pipes, $doc_root, NULL, array("bypass_shell" => true, "suppress_errors" => true)); } else { + $descriptorspec = array( + 0 => STDIN, + 1 => STDOUT, + 2 => STDERR, + ); + $cmd = "exec {$php_executable} -t {$doc_root} -n -S " . PHP_CURL_SERVER_ADDRESS; $cmd .= " {$router}"; $cmd .= " 2>/dev/null"; |