journal: Make the output of --update-catalog deterministic
authorDaniel Edgecumbe <git@esotericnonsense.com>
Thu, 5 Sep 2019 14:34:52 +0000 (15:34 +0100)
committerMichael Biebl <biebl@debian.org>
Tue, 19 Nov 2019 08:17:12 +0000 (08:17 +0000)
commit40a39de31881e010aaeff95c5313a9ca6cdaea32
tree6fafb188d68da79a30e5f96cdb16f17cc4ef1aca
parent703fc0267181e22b88da2fe279bd3e1a830e0f63
journal: Make the output of --update-catalog deterministic

The use of an unordered hashmap means that the output of
'journalctl --update-catalog' differs between runs despite there being no
changes in the input files.

By changing all instances of Hashmap to OrderedHashmap we fix this, and now
the catalog is reproducible.

Motivation: https://reproducible-builds.org

Signed-off-by: Daniel Edgecumbe <git@esotericnonsense.com>
(cherry picked from commit a95686bb5d615a73a14d451a25225a566f9af570)
(cherry picked from commit f500d2fa81292046e5360b49b38a46f34ca1f397)

Gbp-Pq: Name journal-Make-the-output-of-update-catalog-deterministic.patch
src/fuzz/fuzz-catalog.c
src/journal/catalog.c
src/journal/catalog.h
src/journal/test-catalog.c