diff options
Diffstat (limited to 'src/nxt_h1proto.c')
-rw-r--r-- | src/nxt_h1proto.c | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/src/nxt_h1proto.c b/src/nxt_h1proto.c index 3a822042..6bc6c7ee 100644 --- a/src/nxt_h1proto.c +++ b/src/nxt_h1proto.c @@ -35,7 +35,6 @@ static void nxt_h1p_request_body_read(nxt_task_t *task, nxt_http_request_t *r); static void nxt_h1p_conn_request_body_read(nxt_task_t *task, void *obj, void *data); static void nxt_h1p_request_local_addr(nxt_task_t *task, nxt_http_request_t *r); -static void nxt_h1p_request_tls(nxt_task_t *task, nxt_http_request_t *r); static void nxt_h1p_request_header_send(nxt_task_t *task, nxt_http_request_t *r); static void nxt_h1p_request_send(nxt_task_t *task, nxt_http_request_t *r, @@ -104,13 +103,6 @@ const nxt_http_proto_local_addr_t nxt_http_proto_local_addr[3] = { }; -const nxt_http_proto_tls_t nxt_http_proto_tls[3] = { - nxt_h1p_request_tls, - NULL, - NULL, -}; - - const nxt_http_proto_header_send_t nxt_http_proto_header_send[3] = { nxt_h1p_request_header_send, NULL, @@ -448,6 +440,10 @@ nxt_h1p_conn_request_init(nxt_task_t *task, void *obj, void *data) r->remote = c->remote; +#if (NXT_TLS) + r->tls = c->u.tls; +#endif + ret = nxt_http_parse_request_init(&h1p->parser, r->mem_pool); if (nxt_fast_path(ret == NXT_OK)) { @@ -821,15 +817,6 @@ nxt_h1p_request_local_addr(nxt_task_t *task, nxt_http_request_t *r) } -static void -nxt_h1p_request_tls(nxt_task_t *task, nxt_http_request_t *r) -{ -#if (NXT_TLS) - r->tls = r->proto.h1->conn->u.tls; -#endif -} - - #define NXT_HTTP_LAST_SUCCESS \ (NXT_HTTP_OK + nxt_nitems(nxt_http_success) - 1) |