ryantimwilson / rpms / systemd

Forked from rpms/systemd a month ago
Clone
ff6046
From d4c1d109a883fbc5695cf10c79e61bedbe788829 Mon Sep 17 00:00:00 2001
ff6046
From: Lennart Poettering <lennart@poettering.net>
ff6046
Date: Mon, 3 Dec 2018 20:28:15 +0100
ff6046
Subject: [PATCH] format-table: use right field for display
ff6046
ff6046
Since .timespan and .timestamp are unionized on top of each other this
ff6046
doesn't actually matter, but it is still more correct to address it
ff6046
under it's correct name.
ff6046
ff6046
(cherry picked from commit c93d372d7ceda0b080487fa35d3638ef3d8507cb)
ff6046
ff6046
Related: #1689832
ff6046
---
ff6046
 src/basic/format-table.c | 2 +-
ff6046
 1 file changed, 1 insertion(+), 1 deletion(-)
ff6046
ff6046
diff --git a/src/basic/format-table.c b/src/basic/format-table.c
ff6046
index 5517adad82..cfb8aadbda 100644
ff6046
--- a/src/basic/format-table.c
ff6046
+++ b/src/basic/format-table.c
ff6046
@@ -928,7 +928,7 @@ static const char *table_data_format(TableData *d) {
ff6046
                 if (!p)
ff6046
                         return NULL;
ff6046
 
ff6046
-                if (!format_timespan(p, FORMAT_TIMESPAN_MAX, d->timestamp, 0))
ff6046
+                if (!format_timespan(p, FORMAT_TIMESPAN_MAX, d->timespan, 0))
ff6046
                         return "n/a";
ff6046
 
ff6046
                 d->formatted = TAKE_PTR(p);