dns_client: check whether ssl cert is loaded.

This commit is contained in:
Nick Peng
2021-01-28 01:35:26 +08:00
parent 328f44e800
commit f2fc970561
5 changed files with 27 additions and 31 deletions

View File

@@ -516,6 +516,7 @@ static int _config_domain_rule_flag_set(char *domain, unsigned int flag, unsigne
/* add new rule to domain */
if (domain_rule->rules[DOMAIN_RULE_FLAGS] == NULL) {
rule_flags = malloc(sizeof(*rule_flags));
memset(rule_flags, 0, sizeof(*rule_flags));
rule_flags->flags = 0;
domain_rule->rules[DOMAIN_RULE_FLAGS] = rule_flags;
}