networkd: make sure we allocate the NTA set before we add items to it

See: #2683
This commit is contained in:
Lennart Poettering
2016-02-21 22:27:01 +01:00
parent 714c62b463
commit cbbf38aefc
+4
View File
@@ -994,6 +994,10 @@ int config_parse_dnssec_negative_trust_anchors(
continue;
}
r = set_ensure_allocated(&n->dnssec_negative_trust_anchors, &dns_name_hash_ops);
if (r < 0)
return log_oom();
r = set_put(n->dnssec_negative_trust_anchors, w);
if (r < 0)
return log_oom();