]> granicus.if.org Git - apache/commitdiff
use APR_TIME_T_FMT when formatting apr_time_t
authorJeff Trawick <trawick@apache.org>
Wed, 17 Jul 2002 16:08:53 +0000 (16:08 +0000)
committerJeff Trawick <trawick@apache.org>
Wed, 17 Jul 2002 16:08:53 +0000 (16:08 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96099 13f79535-47bb-0310-9956-ffa450edef68

modules/loggers/mod_log_config.c
modules/metadata/mod_expires.c
modules/metadata/mod_headers.c
modules/metadata/mod_usertrack.c

index 1e9542b9030719ca3dbb30304913daf09632d8e3..64230160da5e569ded2179eb3bf629f2b59a0eee 100644 (file)
@@ -545,12 +545,13 @@ static const char *log_request_time(request_rec *r, char *a)
 static const char *log_request_duration(request_rec *r, char *a)
 {
     apr_time_t duration = apr_time_now() - r->request_time;
-    return apr_psprintf(r->pool, "%qd", apr_time_sec(duration));
+    return apr_psprintf(r->pool, "%" APR_TIME_T_FMT, apr_time_sec(duration));
 }
 
 static const char *log_request_duration_microseconds(request_rec *r, char *a)
 {
-    return apr_psprintf(r->pool, "%qd", (apr_time_now() - r->request_time));
+    return apr_psprintf(r->pool, "%" APR_TIME_T_FMT, 
+                        (apr_time_now() - r->request_time));
 }
 
 /* These next two routines use the canonical name:port so that log
index a11475e95afed8552a39b93dacee74d67699fb84..278e094c0cf76a9e35eb85aed544c9a3317f4c43 100644 (file)
@@ -500,7 +500,7 @@ static int add_expires(request_rec *r)
 
     expires = base + additional;
     apr_table_mergen(r->headers_out, "Cache-Control",
-                   apr_psprintf(r->pool, "max-age=%qd",
+                   apr_psprintf(r->pool, "max-age=%" APR_TIME_T_FMT,
                                  apr_time_sec(expires - r->request_time)));
     timestr = apr_palloc(r->pool, APR_RFC822_DATE_LEN);
     apr_rfc822_date(timestr, expires);
index cf42cdfb43494e3dd05438ae6745a76ee3e9b913..a9ea9aa9325b00ba301c877c299e04bb4fc24ec7 100644 (file)
@@ -182,11 +182,12 @@ static const char *constant_item(request_rec *r, char *stuff)
 }
 static const char *header_request_duration(request_rec *r, char *a)
 {
-    return apr_psprintf(r->pool, "D=%qd", (apr_time_now() - r->request_time)); 
+    return apr_psprintf(r->pool, "D=%" APR_TIME_T_FMT, 
+                        (apr_time_now() - r->request_time)); 
 }
 static const char *header_request_time(request_rec *r, char *a)
 {
-    return apr_psprintf(r->pool, "t=%qd", r->request_time);
+    return apr_psprintf(r->pool, "t=%" APR_TIME_T_FMT, r->request_time);
 }
 static const char *header_request_env_var(request_rec *r, char *a)
 {
index a05e83bb2c46e5e36ade8f69994670c47af460ef..a8b9d475acc6d0b021dbefa27c881f40a1414346 100644 (file)
@@ -146,7 +146,8 @@ static void make_cookie(request_rec *r)
     dcfg = ap_get_module_config(r->per_dir_config, &usertrack_module);
 
     /* XXX: hmm, this should really tie in with mod_unique_id */
-    apr_snprintf(cookiebuf, sizeof(cookiebuf), "%s.%qd", rname, apr_time_now());
+    apr_snprintf(cookiebuf, sizeof(cookiebuf), "%s.%" APR_TIME_T_FMT, rname, 
+                 apr_time_now());
 
     if (cls->expires) {