diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-25 04:41:27 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-25 04:41:27 +0000 |
commit | c54018b07a9085c0a3aedbc2bd01a85a3b3e20cf (patch) | |
tree | f6e1d6fcf9f6db3794c418b2f89ecf9e08ff41c8 /server/scoreboard.c | |
parent | Adding debian version 2.4.38-3+deb10u10. (diff) | |
download | apache2-c54018b07a9085c0a3aedbc2bd01a85a3b3e20cf.tar.xz apache2-c54018b07a9085c0a3aedbc2bd01a85a3b3e20cf.zip |
Merging upstream version 2.4.59.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'server/scoreboard.c')
-rw-r--r-- | server/scoreboard.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/server/scoreboard.c b/server/scoreboard.c index 23e3d70..49d1600 100644 --- a/server/scoreboard.c +++ b/server/scoreboard.c @@ -364,6 +364,18 @@ AP_DECLARE(int) ap_exists_scoreboard_image(void) return (ap_scoreboard_image ? 1 : 0); } +AP_DECLARE(void) ap_set_conn_count(ap_sb_handle_t *sb, request_rec *r, + unsigned short conn_count) +{ + worker_score *ws; + + if (!sb) + return; + + ws = &ap_scoreboard_image->servers[sb->child_num][sb->thread_num]; + ws->conn_count = conn_count; +} + AP_DECLARE(void) ap_increment_counts(ap_sb_handle_t *sb, request_rec *r) { worker_score *ws; @@ -376,7 +388,7 @@ AP_DECLARE(void) ap_increment_counts(ap_sb_handle_t *sb, request_rec *r) if (pfn_ap_logio_get_last_bytes != NULL) { bytes = pfn_ap_logio_get_last_bytes(r->connection); } - else if (r->method_number == M_GET && r->method[0] == 'H') { + else if (r->method_number == M_GET && r->method && r->method[0] == 'H') { bytes = 0; } else { @@ -641,7 +653,7 @@ AP_DECLARE(void) ap_time_process_request(ap_sb_handle_t *sbh, int status) } } -AP_DECLARE(int) ap_update_global_status() +AP_DECLARE(int) ap_update_global_status(void) { #ifdef HAVE_TIMES if (ap_scoreboard_image == NULL) { @@ -695,7 +707,7 @@ AP_DECLARE(process_score *) ap_get_scoreboard_process(int x) return &ap_scoreboard_image->parent[x]; } -AP_DECLARE(global_score *) ap_get_scoreboard_global() +AP_DECLARE(global_score *) ap_get_scoreboard_global(void) { return ap_scoreboard_image->global; } |