summaryrefslogtreecommitdiffstats
path: root/src/basic/time-util.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2023-01-20 16:54:22 +0100
committerLennart Poettering <lennart@poettering.net>2023-01-20 17:44:59 +0100
commit9b9ea806ad0ec469ae40c22b34b9e11220f0710a (patch)
tree619211dac0ea28bdd17f7197f30325606a81f37e /src/basic/time-util.c
parenttime-util: simplify formatting of UNIX timestamps (diff)
downloadsystemd-9b9ea806ad0ec469ae40c22b34b9e11220f0710a.tar.xz
systemd-9b9ea806ad0ec469ae40c22b34b9e11220f0710a.zip
time-util: condition size check based on utc mode
Diffstat (limited to 'src/basic/time-util.c')
-rw-r--r--src/basic/time-util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/basic/time-util.c b/src/basic/time-util.c
index dcafad4882..791d83a5d8 100644
--- a/src/basic/time-util.c
+++ b/src/basic/time-util.c
@@ -333,7 +333,7 @@ char *format_timestamp_style(
1 + 10 + /* space and date */
1 + 8 + /* space and time */
(us ? 1 + 6 : 0) + /* "." and microsecond part */
- 1 + 1 + /* space and shortest possible zone */
+ 1 + (utc ? 3 : 1) + /* space and shortest possible zone */
1))
return NULL; /* Not enough space even for the shortest form. */