@@ -13,10 +13,10 @@ function do_test($context_options) {
13
13
$ context = stream_context_create (array ('http ' => $ context_options ));
14
14
15
15
$ responses = array (
16
- "data://text/plain,HTTP/1.0 302 Moved Temporarily \r\nLocation: http://127.0.0.1:12342/foo/bar2 \r\n\r\n1 " ,
17
- "data://text/plain,HTTP/1.0 301 Moved Permanently \r\nLocation: http://127.0.0.1:12342/foo/bar3 \r\n\r\n" ,
18
- "data://text/plain,HTTP/1.0 302 Moved Temporarily \r\nLocation: http://127.0.0.1:12342/foo/bar4 \r\n\r\n3 " ,
19
- "data://text/plain,HTTP/1.0 200 OK \r\n\r\ndone. " ,
16
+ "data://text/plain,HTTP/1.1 302 Moved Temporarily \r\nLocation: http://127.0.0.1:12342/foo/bar2 \r\n\r\n1 " ,
17
+ "data://text/plain,HTTP/1.1 301 Moved Permanently \r\nLocation: http://127.0.0.1:12342/foo/bar3 \r\n\r\n" ,
18
+ "data://text/plain,HTTP/1.1 302 Moved Temporarily \r\nLocation: http://127.0.0.1:12342/foo/bar4 \r\n\r\n3 " ,
19
+ "data://text/plain,HTTP/1.1 200 OK \r\n\r\ndone. " ,
20
20
);
21
21
22
22
$ pid = http_server ("tcp://127.0.0.1:12342 " , $ responses , $ output );
@@ -71,34 +71,34 @@ do_test(array('max_redirects' => 2, 'ignore_errors' => 1), 2);
71
71
resource(%d) of type (stream)
72
72
array(7) {
73
73
[0]=>
74
- string(30) "HTTP/1.0 302 Moved Temporarily"
74
+ string(30) "HTTP/1.1 302 Moved Temporarily"
75
75
[1]=>
76
76
string(41) "Location: http://127.0.0.1:12342/foo/bar2"
77
77
[2]=>
78
- string(30) "HTTP/1.0 301 Moved Permanently"
78
+ string(30) "HTTP/1.1 301 Moved Permanently"
79
79
[3]=>
80
80
string(41) "Location: http://127.0.0.1:12342/foo/bar3"
81
81
[4]=>
82
- string(30) "HTTP/1.0 302 Moved Temporarily"
82
+ string(30) "HTTP/1.1 302 Moved Temporarily"
83
83
[5]=>
84
84
string(41) "Location: http://127.0.0.1:12342/foo/bar4"
85
85
[6]=>
86
- string(15) "HTTP/1.0 200 OK"
86
+ string(15) "HTTP/1.1 200 OK"
87
87
}
88
88
string(5) "done."
89
- string(%d) "GET /foo/bar HTTP/1.0
89
+ string(%d) "GET /foo/bar HTTP/1.1
90
90
Host: 127.0.0.1:12342
91
91
Connection: close
92
92
93
- GET /foo/bar2 HTTP/1.0
93
+ GET /foo/bar2 HTTP/1.1
94
94
Host: 127.0.0.1:12342
95
95
Connection: close
96
96
97
- GET /foo/bar3 HTTP/1.0
97
+ GET /foo/bar3 HTTP/1.1
98
98
Host: 127.0.0.1:12342
99
99
Connection: close
100
100
101
- GET /foo/bar4 HTTP/1.0
101
+ GET /foo/bar4 HTTP/1.1
102
102
Host: 127.0.0.1:12342
103
103
Connection: close
104
104
@@ -107,11 +107,11 @@ Connection: close
107
107
108
108
Warning: fopen(http://127.0.0.1:12342/foo/bar): Failed to open stream: Redirection limit reached, aborting in %s
109
109
bool(false)
110
- string(%d) "GET /foo/bar HTTP/1.0
110
+ string(%d) "GET /foo/bar HTTP/1.1
111
111
Host: 127.0.0.1:12342
112
112
Connection: close
113
113
114
- GET /foo/bar2 HTTP/1.0
114
+ GET /foo/bar2 HTTP/1.1
115
115
Host: 127.0.0.1:12342
116
116
Connection: close
117
117
@@ -120,7 +120,7 @@ Connection: close
120
120
121
121
Warning: fopen(http://127.0.0.1:12342/foo/bar): Failed to open stream: Redirection limit reached, aborting in %s
122
122
bool(false)
123
- string(%d) "GET /foo/bar HTTP/1.0
123
+ string(%d) "GET /foo/bar HTTP/1.1
124
124
Host: 127.0.0.1:12342
125
125
Connection: close
126
126
@@ -129,7 +129,7 @@ Connection: close
129
129
130
130
Warning: fopen(http://127.0.0.1:12342/foo/bar): Failed to open stream: Redirection limit reached, aborting in %s
131
131
bool(false)
132
- string(%d) "GET /foo/bar HTTP/1.0
132
+ string(%d) "GET /foo/bar HTTP/1.1
133
133
Host: 127.0.0.1:12342
134
134
Connection: close
135
135
@@ -138,12 +138,12 @@ Connection: close
138
138
resource(%d) of type (stream)
139
139
array(2) {
140
140
[0]=>
141
- string(30) "HTTP/1.0 302 Moved Temporarily"
141
+ string(30) "HTTP/1.1 302 Moved Temporarily"
142
142
[1]=>
143
143
string(41) "Location: http://127.0.0.1:12342/foo/bar2"
144
144
}
145
145
string(1) "1"
146
- string(%d) "GET /foo/bar HTTP/1.0
146
+ string(%d) "GET /foo/bar HTTP/1.1
147
147
Host: 127.0.0.1:12342
148
148
Connection: close
149
149
@@ -152,12 +152,12 @@ Connection: close
152
152
resource(%d) of type (stream)
153
153
array(2) {
154
154
[0]=>
155
- string(30) "HTTP/1.0 302 Moved Temporarily"
155
+ string(30) "HTTP/1.1 302 Moved Temporarily"
156
156
[1]=>
157
157
string(41) "Location: http://127.0.0.1:12342/foo/bar2"
158
158
}
159
159
string(1) "1"
160
- string(%d) "GET /foo/bar HTTP/1.0
160
+ string(%d) "GET /foo/bar HTTP/1.1
161
161
Host: 127.0.0.1:12342
162
162
Connection: close
163
163
@@ -166,20 +166,20 @@ Connection: close
166
166
resource(%d) of type (stream)
167
167
array(4) {
168
168
[0]=>
169
- string(30) "HTTP/1.0 302 Moved Temporarily"
169
+ string(30) "HTTP/1.1 302 Moved Temporarily"
170
170
[1]=>
171
171
string(41) "Location: http://127.0.0.1:12342/foo/bar2"
172
172
[2]=>
173
- string(30) "HTTP/1.0 301 Moved Permanently"
173
+ string(30) "HTTP/1.1 301 Moved Permanently"
174
174
[3]=>
175
175
string(41) "Location: http://127.0.0.1:12342/foo/bar3"
176
176
}
177
177
string(0) ""
178
- string(%d) "GET /foo/bar HTTP/1.0
178
+ string(%d) "GET /foo/bar HTTP/1.1
179
179
Host: 127.0.0.1:12342
180
180
Connection: close
181
181
182
- GET /foo/bar2 HTTP/1.0
182
+ GET /foo/bar2 HTTP/1.1
183
183
Host: 127.0.0.1:12342
184
184
Connection: close
185
185
0 commit comments