MCPcopy Create free account
hub / github.com/apache/httpd / h2_request_end_headers

Function h2_request_end_headers

modules/http2/h2_request.c:198–218  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

196}
197
198apr_status_t h2_request_end_headers(h2_request *req, apr_pool_t *pool,
199 size_t raw_bytes)
200{
201 /* rfc7540, ch. 8.1.2.3: without :authority, Host: must be there */
202 if (req->authority && !strlen(req->authority)) {
203 req->authority = NULL;
204 }
205 if (!req->authority) {
206 const char *host = apr_table_get(req->headers, "Host");
207 if (!host) {
208 return APR_BADARG;
209 }
210 req->authority = host;
211 }
212 else {
213 apr_table_setn(req->headers, "Host", req->authority);
214 }
215 req->raw_bytes += raw_bytes;
216
217 return APR_SUCCESS;
218}
219
220h2_request *h2_request_clone(apr_pool_t *p, const h2_request *src)
221{

Callers 2

h2_stream_end_headersFunction · 0.85
add_pushFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected