Wildcards in dhcp-range constructors

This commit is contained in:
Simon Kelley committed 2012-12-30 17:38:09 +00:00
1 parent dc9476b670
commit 771287be11
4 files changed
+17 -6

No files matched your search

+5
View File
@@ -2291,6 +2291,11 @@ static int one_opt(int option, char *arg, char *errstr, char *gen_err, int comma
new->flags |= CONTEXT_DHCP;
else if (strstr(a[leasepos], "constructor:") == a[leasepos])
{
if (a[leasepos][strlen(a[leasepos])-1] == '*')
{
a[leasepos][strlen(a[leasepos])-1] = 0;
new->flags |= CONTEXT_WILDCARD;
}
new->template_interface = opt_string_alloc(a[leasepos] + 12);
new->flags |= CONTEXT_TEMPLATE;
}