]> granicus.if.org Git - apache/commitdiff
Replaced APR_USEC_PER_SEC division with apr_time_sec macro
authorBrian Pane <brianp@apache.org>
Sun, 30 Jun 2002 18:20:13 +0000 (18:20 +0000)
committerBrian Pane <brianp@apache.org>
Sun, 30 Jun 2002 18:20:13 +0000 (18:20 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95917 13f79535-47bb-0310-9956-ffa450edef68

modules/generators/mod_status.c

index bd476cefc1f5f0d2f70fc510cfa53c951a7a1277..b8bccf509527071c81ced8f43e34e019051ed9ec 100644 (file)
@@ -384,9 +384,8 @@ static int status_handler(request_rec *r)
     }
 
     /* up_time in seconds */
-    up_time = (apr_uint32_t) ((nowtime -
-                               ap_scoreboard_image->global->restart_time)
-                              / APR_USEC_PER_SEC);
+    up_time = (apr_uint32_t) apr_time_sec(nowtime -
+                               ap_scoreboard_image->global->restart_time);
 
     if (!short_report) {
         ap_rputs(DOCTYPE_HTML_3_2
@@ -648,8 +647,8 @@ static int status_handler(request_rec *r)
                                ws_record->times.tms_cutime / tick,
                                ws_record->times.tms_cstime / tick,
 #endif
-                               (long)((nowtime - ws_record->last_used) /
-                                      APR_USEC_PER_SEC),
+                               (long)apr_time_sec(nowtime -
+                                                  ws_record->last_used),
                                (long) req_time);
 
                     format_byte_out(r, conn_bytes);
@@ -733,8 +732,8 @@ static int status_handler(request_rec *r)
                                 ws_record->times.tms_cutime +
                                 ws_record->times.tms_cstime) / tick,
 #endif
-                               (long)((nowtime - ws_record->last_used) /
-                                      APR_USEC_PER_SEC),
+                               (long)apr_time_sec(nowtime -
+                                                  ws_record->last_used),
                                (long)req_time);
                     
                     ap_rprintf(r, "</td><td>%-1.1f</td><td>%-2.2f</td><td>%-2.2f\n",