You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by yl...@apache.org on 2021/09/07 01:09:23 UTC
svn commit: r1893001 - /httpd/httpd/trunk/server/protocol.c
Author: ylavic
Date: Tue Sep 7 01:09:23 2021
New Revision: 1893001
URL: http://svn.apache.org/viewvc?rev=1893001&view=rev
Log:
core: Set r->request_time before any logging, mod_unique_id needs it.
* server/protocol.c(read_request_line):
Move r->request_time initialization before first APLOG_TRACE5,
ap_log_rerror() may run the generate_log_id hooks and call mod_unique_id
with no timestamp initialized (zero).
Modified:
httpd/httpd/trunk/server/protocol.c
Modified: httpd/httpd/trunk/server/protocol.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/protocol.c?rev=1893001&r1=1893000&r2=1893001&view=diff
==============================================================================
--- httpd/httpd/trunk/server/protocol.c (original)
+++ httpd/httpd/trunk/server/protocol.c Tue Sep 7 01:09:23 2021
@@ -738,13 +738,15 @@ static int read_request_line(request_rec
}
} while ((len <= 0) && (--num_blank_lines >= 0));
+ /* Set r->request_time before any logging, mod_unique_id needs it. */
+ r->request_time = apr_time_now();
+
if (APLOGrtrace5(r)) {
ap_log_rerror(APLOG_MARK, APLOG_TRACE5, 0, r,
"Request received from client: %s",
ap_escape_logitem(r->pool, r->the_request));
}
- r->request_time = apr_time_now();
return 1;
}