"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "mod_http2/mod_http2.c" between
mod_http2-1.15.16.tar.gz and mod_http2-1.15.17.tar.gz

About: mod_h[ttp]2 is an Apache httpd module implementing the HTTP2 protocol. It uses nghttp2 as base engine and connects it with the Apache infrastructure. Hint: Module (previous name "mod_h2") now integrated into Apache httpd (since v2.4.17). Experimental release.

mod_http2.c  (mod_http2-1.15.16):mod_http2.c  (mod_http2-1.15.17)
skipping to change at line 182 skipping to change at line 182
static int http2_is_h2(conn_rec *); static int http2_is_h2(conn_rec *);
static void http2_get_num_workers(server_rec *s, int *minw, int *maxw) static void http2_get_num_workers(server_rec *s, int *minw, int *maxw)
{ {
h2_get_num_workers(s, minw, maxw); h2_get_num_workers(s, minw, maxw);
} }
/* Runs once per created child process. Perform any process /* Runs once per created child process. Perform any process
* related initionalization here. * related initionalization here.
*/ */
static void h2_child_init(apr_pool_t *pool, server_rec *s) static void h2_child_init(apr_pool_t *pchild, server_rec *s)
{ {
apr_allocator_t *allocator;
apr_thread_mutex_t *mutex;
apr_status_t status;
/* The allocator of pchild has no mutex with MPM prefork, but we need one
* for h2 workers threads synchronization. Even though mod_http2 shouldn't
* be used with prefork, better be safe than sorry, so forcibly set the
* mutex here. For MPM event/worker, pchild has no allocator so pconf's
* is used, with its mutex.
*/
allocator = apr_pool_allocator_get(pchild);
if (allocator) {
mutex = apr_allocator_mutex_get(allocator);
if (!mutex) {
apr_thread_mutex_create(&mutex, APR_THREAD_MUTEX_DEFAULT, pchild);
apr_allocator_mutex_set(allocator, mutex);
}
}
/* Set up our connection processing */ /* Set up our connection processing */
apr_status_t status = h2_conn_child_init(pool, s); status = h2_conn_child_init(pchild, s);
if (status != APR_SUCCESS) { if (status != APR_SUCCESS) {
ap_log_error(APLOG_MARK, APLOG_ERR, status, s, ap_log_error(APLOG_MARK, APLOG_ERR, status, s,
APLOGNO(02949) "initializing connection handling"); APLOGNO(02949) "initializing connection handling");
} }
} }
/* Install this module into the apache2 infrastructure. /* Install this module into the apache2 infrastructure.
*/ */
static void h2_hooks(apr_pool_t *pool) static void h2_hooks(apr_pool_t *pool)
{ {
static const char *const mod_ssl[] = { "mod_ssl.c", NULL}; static const char *const mod_ssl[] = { "mod_ssl.c", NULL};
APR_REGISTER_OPTIONAL_FN(http2_is_h2); APR_REGISTER_OPTIONAL_FN(http2_is_h2);
APR_REGISTER_OPTIONAL_FN(http2_var_lookup); APR_REGISTER_OPTIONAL_FN(http2_var_lookup);
 End of changes. 4 change blocks. 
3 lines changed or deleted 21 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)