Port: Use portable format string for ISO 8601 dates
authorMichael Jeanson <mjeanson@efficios.com>
Thu, 12 Jan 2017 17:08:26 +0000 (12:08 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 9 Jun 2017 20:58:15 +0000 (16:58 -0400)
The %F format string to reprensent ISO 8601 dates is specific to C99 and
not available on all platforms, use basic %Y-%m-%d to get the same
result.

Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
plugins/text/pretty/print.c

index 0545178efb48af6a2010d0cf8695f34efd165586..86c088dc6c5d2f638758e374d28b1fe8fc84bece 100644 (file)
@@ -224,7 +224,7 @@ void print_timestamp_wall(struct pretty_component *pretty,
 
                        /* Print date and time */
                        res = strftime(timestr, sizeof(timestr),
-                                       "%F ", &tm);
+                                       "%Y-%m-%d ", &tm);
                        if (!res) {
                                // TODO: log instead
                                fprintf(stderr, "[warning] Unable to print ascii time.\n");
This page took 0.025487 seconds and 4 git commands to generate.