diff options
author | Frantisek Sumsal <frantisek@sumsal.cz> | 2022-03-14 18:43:03 +0100 |
---|---|---|
committer | Frantisek Sumsal <frantisek@sumsal.cz> | 2022-03-14 23:33:59 +0100 |
commit | f01aafd283e0302d12ab7e7f31675c302bf5d798 (patch) | |
tree | 3018df3c7ad3e6d989a78c3ae3de946f612a396a | |
parent | 8e4b9a252b434b7f8c74271df8dc4f07d7960c32 (diff) | |
download | systemd-f01aafd283e0302d12ab7e7f31675c302bf5d798.tar.gz |
journal: make --reverse affect --list-boots
Fixes: #16274
-rw-r--r-- | src/journal/journalctl.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c index 55c48eded5..63334c0ea4 100644 --- a/src/journal/journalctl.c +++ b/src/journal/journalctl.c @@ -1471,6 +1471,9 @@ static int list_boots(sd_journal *j) { if (r < 0) return log_error_errno(r, "Failed to set JSON field name of column 0: %m"); + (void) table_set_sort(table, (size_t) 0); + (void) table_set_reverse(table, 0, arg_reverse); + i = 0; LIST_FOREACH(boot_list, id, all_ids) { r = table_add_many(table, |