diff options
author | Stefan Eissing <icing@apache.org> | 2015-11-03 15:33:11 +0100 |
---|---|---|
committer | Stefan Eissing <icing@apache.org> | 2015-11-03 15:33:11 +0100 |
commit | 0b107b1c464cb6ec66d11ac0c4ced0694954d45e (patch) | |
tree | 73b86b9bc075ee5a696e148f031b2afcef06987c /modules/http2/h2_conn.c | |
parent | fixing compile errors due to if assignment warnings (diff) | |
download | apache2-0b107b1c464cb6ec66d11ac0c4ced0694954d45e.tar.xz apache2-0b107b1c464cb6ec66d11ac0c4ced0694954d45e.zip |
rework of output handling on stream/session close, rework of cleartext (http:) output to pass buckets to core filters, splitting of stream/io memory pools for stability and less sync
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1712300 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules/http2/h2_conn.c')
-rw-r--r-- | modules/http2/h2_conn.c | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/modules/http2/h2_conn.c b/modules/http2/h2_conn.c index b246f87a31..877447e2ff 100644 --- a/modules/http2/h2_conn.c +++ b/modules/http2/h2_conn.c @@ -240,7 +240,7 @@ static apr_status_t h2_conn_loop(h2_session *session) session->c->local_addr->port); if (status != APR_SUCCESS) { h2_session_abort(session, status, rv); - h2_session_destroy(session); + h2_session_cleanup(session); return status; } @@ -343,12 +343,9 @@ static apr_status_t h2_conn_loop(h2_session *session) ap_log_cerror( APLOG_MARK, APLOG_DEBUG, status, session->c, "h2_session(%ld): done", session->id); + h2_session_close(session); ap_update_child_status_from_conn(session->c->sbh, SERVER_CLOSING, session->c); - - h2_session_close(session); - h2_session_destroy(session); - return DONE; } @@ -411,11 +408,11 @@ conn_rec *h2_conn_create(conn_rec *master, apr_pool_t *pool) return c; } -apr_status_t h2_conn_setup(h2_task_env *env, struct h2_worker *worker) +apr_status_t h2_conn_setup(h2_task *task, struct h2_worker *worker) { - conn_rec *master = env->mplx->c; + conn_rec *master = task->mplx->c; - ap_log_perror(APLOG_MARK, APLOG_TRACE3, 0, env->pool, + ap_log_perror(APLOG_MARK, APLOG_TRACE3, 0, task->pool, "h2_conn(%ld): created from master", master->id); /* Ok, we are just about to start processing the connection and @@ -424,17 +421,17 @@ apr_status_t h2_conn_setup(h2_task_env *env, struct h2_worker *worker) * sub-resources from it, so that we get a nice reuse of * pools. */ - env->c.pool = env->pool; - env->c.bucket_alloc = h2_worker_get_bucket_alloc(worker); - env->c.current_thread = h2_worker_get_thread(worker); + task->c->pool = task->pool; + task->c->bucket_alloc = h2_worker_get_bucket_alloc(worker); + task->c->current_thread = h2_worker_get_thread(worker); - env->c.conn_config = ap_create_conn_config(env->pool); - env->c.notes = apr_table_make(env->pool, 5); + task->c->conn_config = ap_create_conn_config(task->pool); + task->c->notes = apr_table_make(task->pool, 5); /* In order to do this in 2.4.x, we need to add a member to conn_rec */ - env->c.master = master; + task->c->master = master; - ap_set_module_config(env->c.conn_config, &core_module, + ap_set_module_config(task->c->conn_config, &core_module, h2_worker_get_socket(worker)); /* This works for mpm_worker so far. Other mpm modules have @@ -446,7 +443,7 @@ apr_status_t h2_conn_setup(h2_task_env *env, struct h2_worker *worker) /* all fine */ break; case H2_MPM_EVENT: - fix_event_conn(&env->c, master); + fix_event_conn(task->c, master); break; default: /* fingers crossed */ @@ -458,7 +455,7 @@ apr_status_t h2_conn_setup(h2_task_env *env, struct h2_worker *worker) * 400 Bad Request * when names do not match. We prefer a predictable 421 status. */ - env->c.keepalives = 1; + task->c->keepalives = 1; return APR_SUCCESS; } |