Skip to content

Commit 317a3f2

Browse files
Fix generation of per request CPU times in event data.
1 parent 6c0ad4e commit 317a3f2

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

docs/release-notes/version-4.5.1.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,9 @@ Version 4.5.1
55
Version 4.5.1 of mod_wsgi can be obtained from:
66

77
https://codeload.github.com/GrahamDumpleton/mod_wsgi/tar.gz/4.5.1
8+
9+
Bugs Fixed
10+
----------
11+
12+
1. The CPU user and system time for requests wasn't always being output
13+
in request finished event data.

src/server/mod_wsgi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3225,7 +3225,7 @@ static int Adapter_run(AdapterObject *self, PyObject *object)
32253225
if (application_time < 0.0)
32263226
application_time = 0.0;
32273227

3228-
if (end_usage.user_time != 0.0) {
3228+
if (start_usage.user_time != 0.0) {
32293229
if (wsgi_thread_cpu_usage(&end_usage)) {
32303230
double user_seconds;
32313231
double system_seconds;

0 commit comments

Comments
 (0)