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>
Fri, 15 Nov 2019 21:01:17 +0000 (21:01 +0000)
commit5e3cc375ef93b4b4d44cdc1669751cb8e24a47f0
tree21247a7ad5a6a8f6d7305a18ad73e967ade370a9
parent78ec2ef3c344878ef02a9ca9aaa90d301c55681a
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