diff options
| author | Rowan Tommins <git@rwec.co.uk> | 2020-06-11 19:05:00 +0100 |
|---|---|---|
| committer | Nikita Popov <nikita.ppv@gmail.com> | 2020-08-03 16:30:09 +0200 |
| commit | f9f769d4b9af367af864d35cf09dca5b08da2046 (patch) | |
| tree | 67a8404011e152302460962f980c68e36e932f3f /sapi/cli/tests | |
| parent | 9b975fe98e88c3fd5c41fe6b209b715cf190887a (diff) | |
| download | php-git-f9f769d4b9af367af864d35cf09dca5b08da2046.tar.gz | |
Make http stream wrapper advertise HTTP/1.1 by default
In practice, we always act as an HTTP/1.1 client, for compatibility
with servers which ignore protocol version. Sending the version in
the request will avoid problems with servers which don't ignore it.
HTTP/1.0 can still be forced using a stream context option.
Closes GH-5899.
Diffstat (limited to 'sapi/cli/tests')
| -rw-r--r-- | sapi/cli/tests/bug69655.phpt | 6 | ||||
| -rw-r--r-- | sapi/cli/tests/bug70264.phpt | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/sapi/cli/tests/bug69655.phpt b/sapi/cli/tests/bug69655.phpt index dbb9a6af40..b5612357f9 100644 --- a/sapi/cli/tests/bug69655.phpt +++ b/sapi/cli/tests/bug69655.phpt @@ -17,11 +17,11 @@ foreach (['MKCO', 'MKCOLL', 'M'] as $method) { } ?> --EXPECTF-- -Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.0 501 Not Implemented +Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.1 501 Not Implemented in %s on line %d -Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.0 501 Not Implemented +Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.1 501 Not Implemented in %s on line %d -Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.0 501 Not Implemented +Warning: file_get_contents(http://localhost:8964): Failed to open stream: HTTP request failed! HTTP/1.1 501 Not Implemented in %s on line %d diff --git a/sapi/cli/tests/bug70264.phpt b/sapi/cli/tests/bug70264.phpt index 6d4ee15273..e1b0ee8fe8 100644 --- a/sapi/cli/tests/bug70264.phpt +++ b/sapi/cli/tests/bug70264.phpt @@ -14,8 +14,8 @@ echo file_get_contents("http://" . PHP_CLI_SERVER_ADDRESS . "/..\\CREDITS"); echo file_get_contents("http://" . PHP_CLI_SERVER_ADDRESS . "/..%5CCREDITS"); ?> --EXPECTF-- -Warning: file_get_contents(http://%s/..\CREDITS): Failed to open stream: HTTP request failed! HTTP/1.0 404 Not Found +Warning: file_get_contents(http://%s/..\CREDITS): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in %sbug70264.php on line %d -Warning: file_get_contents(http://%s/..%5CCREDITS): Failed to open stream: HTTP request failed! HTTP/1.0 404 Not Found +Warning: file_get_contents(http://%s/..%5CCREDITS): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in %sbug70264.php on line %d |
