aboutsummaryrefslogtreecommitdiff
path: root/src/common/util.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-04-23 09:13:24 -0400
committerNick Mathewson <nickm@torproject.org>2018-04-23 09:13:24 -0400
commitcd3fc2aa4867e89877bbfb99f4f767d761b91f25 (patch)
tree5ff12068373e17f8218907d153f67b6c8c9fcc26 /src/common/util.c
parent8c01aee2e3b8970af96f5b1a662bdf80d0e22489 (diff)
parentdca36eff8fbe9307aa2f74d26841399537e11406 (diff)
downloadtor-cd3fc2aa4867e89877bbfb99f4f767d761b91f25.tar.gz
tor-cd3fc2aa4867e89877bbfb99f4f767d761b91f25.zip
Merge remote-tracking branch 'neel/b25511-r4'
Diffstat (limited to 'src/common/util.c')
-rw-r--r--src/common/util.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/common/util.c b/src/common/util.c
index b14b6f3979..53e4507f1f 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -1834,6 +1834,15 @@ format_iso_time(char *buf, time_t t)
strftime(buf, ISO_TIME_LEN+1, "%Y-%m-%d %H:%M:%S", tor_gmtime_r(&t, &tm));
}
+/** As format_local_iso_time, but use the yyyy-mm-ddThh:mm:ss format to avoid
+ * embedding an internal space. */
+void
+format_local_iso_time_nospace(char *buf, time_t t)
+{
+ format_local_iso_time(buf, t);
+ buf[10] = 'T';
+}
+
/** As format_iso_time, but use the yyyy-mm-ddThh:mm:ss format to avoid
* embedding an internal space. */
void