We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 582c8ef commit 0476f09Copy full SHA for 0476f09
ext/standard/tests/http/gh16810.phpt
@@ -0,0 +1,26 @@
1
+--TEST--
2
+Bug #79265 variation: "host:" not at start of header
3
+--INI--
4
+allow_url_fopen=1
5
+--SKIPIF--
6
+<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
7
+--FILE--
8
+<?php
9
+$uri = "http://www.example.com";
10
+$config = [
11
+'http' => [
12
+'timeout' => PHP_INT_MIN,
13
+],
14
+];
15
+$ctx = stream_context_create($config);
16
+var_dump(fopen($uri, "r", false, $ctx));
17
+
18
+$config['http']['timeout'] = PHP_INT_MAX;
19
20
21
+?>
22
+--EXPECTF--
23
+resource(%d) of type (stream)
24
25
+Warning: fopen(http://www.example.com): Failed to open stream: timeout must be lower than %d in %s on line %d
26
+bool(false)
0 commit comments