resolved: when dumping trust anchor contents, clarify when it is empty

This commit is contained in:
Lennart Poettering 2016-01-05 20:27:29 +01:00
parent 3eb6aa009d
commit 105f6c4bdc

View file

@ -346,6 +346,9 @@ static void dns_trust_anchor_dump(DnsTrustAnchor *d) {
assert(d);
if (hashmap_isempty(d->positive_by_key))
log_info("No positive trust anchors defined.");
else {
log_info("Positive Trust Anchors:");
HASHMAP_FOREACH(a, d->positive_by_key, i) {
DnsResourceRecord *rr;
@ -353,8 +356,11 @@ static void dns_trust_anchor_dump(DnsTrustAnchor *d) {
DNS_ANSWER_FOREACH(rr, a)
log_info("%s", dns_resource_record_to_string(rr));
}
}
if (!set_isempty(d->negative_by_name)) {
if (set_isempty(d->negative_by_name))
log_info("No negative trust anchors defined.");
else {
char *n;
log_info("Negative trust anchors:");