Support IDN in --auth-zone.

This commit is contained in:
Simon Kelley
2021-10-06 23:48:06 +01:00
parent 39a625ff72
commit c166c07a93

View File

@@ -2227,8 +2227,10 @@ static int one_opt(int option, char *arg, char *errstr, char *gen_err, int comma
comma = split(arg); comma = split(arg);
new = opt_malloc(sizeof(struct auth_zone)); new = opt_malloc(sizeof(struct auth_zone));
new->domain = opt_string_alloc(arg); new->domain = canonicalise_opt(arg);
new->subnet = NULL; if (!new->domain)
ret_err_free(_("invalid auth-zone"), new);
new->subnet = NULL;
new->exclude = NULL; new->exclude = NULL;
new->interface_names = NULL; new->interface_names = NULL;
new->next = daemon->auth_zones; new->next = daemon->auth_zones;