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

Function c2_run_pre_connection

modules/http2/h2_c2.c:644–665  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

642#else /* AP_HAS_RESPONSE_BUCKETS */
643
644static apr_status_t c2_run_pre_connection(conn_rec *c2, apr_socket_t *csd)
645{
646 if (c2->keepalives == 0) {
647 /* Simulate that we had already a request on this connection. Some
648 * hooks trigger special behaviour when keepalives is 0.
649 * (Not necessarily in pre_connection, but later. Set it here, so it
650 * is in place.) */
651 c2->keepalives = 1;
652 /* We signal that this connection will be closed after the request.
653 * Which is true in that sense that we throw away all traffic data
654 * on this c2 connection after each requests. Although we might
655 * reuse internal structures like memory pools.
656 * The wanted effect of this is that httpd does not try to clean up
657 * any dangling data on this connection when a request is done. Which
658 * is unnecessary on a h2 stream.
659 */
660 c2->keepalive = AP_CONN_CLOSE;
661 return ap_run_pre_connection(c2, csd);
662 }
663 ap_assert(c2->output_filters);
664 return APR_SUCCESS;
665}
666
667apr_status_t h2_c2_process(conn_rec *c2, apr_thread_t *thread, int worker_id)
668{

Callers 1

h2_c2_processFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected