summaryrefslogtreecommitdiff
path: root/time
diff options
context:
space:
mode:
authorrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>1999-12-30 18:31:28 +0000
committerrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>1999-12-30 18:31:28 +0000
commitbcbdd878bb4b49c6aa541e719e154883f9410ec2 (patch)
treec4f064ba2c990c9e29b481fe183575f40c6043a2 /time
parent78b0e65f9c522ad48fc003a04e2a749a2a3563ef (diff)
downloadlibapr-bcbdd878bb4b49c6aa541e719e154883f9410ec2.tar.gz
Some changes to the ap_strftime function. We now inform the user of the
length of the string written, and we return a status code. I expect the status code to mean a bit more on Windows than it currently does on Unix. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@59558 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'time')
-rw-r--r--time/unix/timestr.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/time/unix/timestr.c b/time/unix/timestr.c
index 830357560..548e9cdd9 100644
--- a/time/unix/timestr.c
+++ b/time/unix/timestr.c
@@ -126,8 +126,10 @@ ap_status_t ap_timestr(char **date_str, struct atime_t *t, ap_timetype_e type, a
*/
}
-ap_status_t ap_strftime(char *s, ap_size_t max, const char *format, struct atime_t *tm)
+ap_status_t ap_strftime(char *s, ap_int32_t *retsize, ap_size_t max,
+ const char *format, struct atime_t *tm)
{
- strftime(s, max, format, tm->explodedtime);
+ (*retsize) = strftime(s, max, format, tm->explodedtime);
+ return APR_SUCCESS;
}