Skip to content

Commit 9fb4cf8

Browse files
committed
Prevent duplicate request header size gathering
I'm not sure why but this was happening twice. mod_log_forensic.c seemed to make use of this hook for inspecting the request, so I thought it would be safe...
1 parent c70ce8f commit 9fb4cf8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

mod_log_header_size.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,9 @@ static int log_header_size_pre_config(apr_pool_t *p, apr_pool_t *plog, apr_pool_
7171
static int log_header_size_post_read_request(request_rec *r)
7272
{
7373
log_header_size_config_t *cf = ap_get_module_config(r->connection->conn_config, &log_header_size_module);
74-
apr_table_do(gather_header_size, &cf->bytes_in_header, r->headers_in, NULL);
74+
if (cf->bytes_in_header == 0) {
75+
apr_table_do(gather_header_size, &cf->bytes_in_header, r->headers_in, NULL);
76+
}
7577

7678
return OK;
7779
}

0 commit comments

Comments
 (0)