summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorStefan Eissing <icing@apache.org>2016-12-23 12:42:35 +0000
committerStefan Eissing <icing@apache.org>2016-12-23 12:42:35 +0000
commite84ccb6805c96ba0f4b084f7f2126828468313cd (patch)
treeaf0d0db9f6cf9602863113b8807133f0e3cd04db /modules
parentb7a49f46f666806e6c6b3f498ac2833f34e735b0 (diff)
downloadhttpd-e84ccb6805c96ba0f4b084f7f2126828468313cd.tar.gz
On the trunk:
Cleanup mod_http2 beamer registry on server reload. Fixes PR60510. * modules/http2/h2_bucket_beam.c register cleanup function on installation that NULLs the beamer registry on pool cleanup. Patch by: Pavel Mateja <pavel@verotel.cz me git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1775833 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules')
-rw-r--r--modules/http2/h2_bucket_beam.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/modules/http2/h2_bucket_beam.c b/modules/http2/h2_bucket_beam.c
index 3d78a7937d..6d0b04920d 100644
--- a/modules/http2/h2_bucket_beam.c
+++ b/modules/http2/h2_bucket_beam.c
@@ -153,10 +153,19 @@ const apr_bucket_type_t h2_bucket_type_beam = {
******************************************************************************/
static apr_array_header_t *beamers;
-
+
+static apr_status_t cleanup_beamers(void *dummy)
+{
+ (void)dummy;
+ beamers = NULL;
+ return APR_SUCCESS;
+}
+
void h2_register_bucket_beamer(h2_bucket_beamer *beamer)
{
if (!beamers) {
+ apr_pool_cleanup_register(apr_hook_global_pool, NULL,
+ cleanup_beamers, apr_pool_cleanup_null);
beamers = apr_array_make(apr_hook_global_pool, 10,
sizeof(h2_bucket_beamer*));
}