summaryrefslogtreecommitdiff
path: root/src/timezone/strftime.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/timezone/strftime.c')
-rw-r--r--src/timezone/strftime.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/timezone/strftime.c b/src/timezone/strftime.c
index 217dd375f36..4b942c393a3 100644
--- a/src/timezone/strftime.c
+++ b/src/timezone/strftime.c
@@ -114,10 +114,16 @@ enum warn
static char *_add(const char *, char *, const char *);
static char *_conv(int, const char *, char *, const char *);
static char *_fmt(const char *, const struct pg_tm *, char *, const char *,
- enum warn *);
+ enum warn *);
static char *_yconv(int, int, bool, bool, char *, char const *);
+/*
+ * Convert timestamp t to string s, a caller-allocated buffer of size maxsize,
+ * using the given format pattern.
+ *
+ * See also timestamptz_to_str.
+ */
size_t
pg_strftime(char *s, size_t maxsize, const char *format, const struct pg_tm *t)
{
@@ -499,7 +505,7 @@ _fmt(const char *format, const struct pg_tm *t, char *pt,
static char *
_conv(int n, const char *format, char *pt, const char *ptlim)
{
- char buf[INT_STRLEN_MAXIMUM(int) +1];
+ char buf[INT_STRLEN_MAXIMUM(int) + 1];
sprintf(buf, format, n);
return _add(buf, pt, ptlim);