Lines Matching refs:arg

226   char * const arg;
641 if (usage[i].arg)
643 strcpy(buff, usage[i].arg);
645 if (tab[j].handle == *(usage[i].arg))
666 static char *parse_dhcp_opt(char *arg, int flags)
681 while (arg)
683 comma = split(arg);
685 for (cp = arg; *cp; cp++)
691 new->opt = atoi(arg);
696 if (strstr(arg, "option:") == arg)
700 strcasecmp(opttab[i].name, arg+7) == 0)
709 else if (strstr(arg, "vendor:") == arg)
711 new->u.vendor_class = (unsigned char *)opt_string_alloc(arg+7);
714 else if (strstr(arg, "encap:") == arg)
716 new->u.encap = atoi(arg+6);
723 if (strstr(arg, "net:") == arg)
724 new->netid->net = opt_string_alloc(arg+4);
726 new->netid->net = opt_string_alloc(arg);
731 arg = comma;
805 /* assume numeric arg is 1 byte except for
874 /* text arg */
883 arg = comma;
884 comma = split(arg);
886 while (arg && *arg)
889 if (!(dom = arg = canonicalise_opt(arg)))
895 newp = opt_malloc(len + strlen(arg) + 2 + header_size);
903 while (*arg)
907 for (j = 0; *arg && (*arg != '.'); arg++, j++)
908 *q++ = *arg;
910 if (*arg)
911 arg++;
929 arg = comma;
930 comma = split(arg);
978 static char *one_opt(int option, char *arg, char *gen_prob, int nest)
1021 char *file = opt_string_alloc(arg);
1040 comma = split(arg);
1041 if (!(directory = opt_string_alloc(arg)))
1044 for (arg = comma; arg; arg = comma)
1046 comma = split(arg);
1051 li->suffix = opt_string_alloc(arg);
1110 if (strchr(arg, '/'))
1111 daemon->log_file = opt_string_alloc(arg);
1118 if (hostname_isequal((char *)facilitynames[i].c_name, arg))
1130 daemon->runfile = opt_string_alloc(arg);
1137 daemon->dhcp_hosts_file = opt_string_alloc(arg);
1144 daemon->dhcp_opts_file = opt_string_alloc(arg);
1149 char *name = opt_string_alloc(arg);
1183 if ((comma = split(arg)))
1190 if (!(name = canonicalise_opt(arg)) ||
1205 if (!(daemon->mxtarget = canonicalise_opt(arg)))
1211 daemon->lease_file = opt_string_alloc(arg);
1220 daemon->lease_change_command = opt_string_alloc(arg);
1229 new->fname = opt_string_alloc(arg);
1238 if (strcmp (arg, "#") == 0)
1243 comma = split(arg);
1244 if (!(d = canonicalise_opt(arg)))
1252 if ((arg = split_chr(comma, '/')))
1256 !atoi_check(arg, &mask))
1265 else if ((arg = split(comma)))
1268 (new->end.s_addr = inet_addr(arg)) == (in_addr_t)-1)
1285 daemon->username = opt_string_alloc(arg);
1289 daemon->groupname = opt_string_alloc(arg);
1295 daemon->scriptuser = opt_string_alloc(arg);
1302 comma = split(arg);
1307 new->name = opt_string_alloc(arg);
1309 arg = comma;
1310 } while (arg);
1317 comma = split(arg);
1318 new->name = opt_string_alloc(arg);
1329 arg = comma;
1330 } while (arg);
1336 unhide_metas(arg);
1337 if (arg && (addr.s_addr = inet_addr(arg)) != (in_addr_t)-1)
1352 comma = split(arg);
1353 unhide_metas(arg);
1355 if (arg && (new->addr.in.sin_addr.s_addr = inet_addr(arg)) != (in_addr_t)-1)
1363 else if (arg && inet_pton(AF_INET6, arg, &new->addr.in6.sin6_addr) > 0)
1380 arg = comma;
1381 } while (arg);
1390 unhide_metas(arg);
1392 if (arg && *arg == '/')
1395 arg++;
1396 while ((end = split_chr(arg, '/')))
1400 if (strcmp(arg, "#") == 0)
1402 else if (strlen (arg) != 0 && !(domain = canonicalise_opt(arg)))
1410 arg = end;
1432 if (!arg || !*arg)
1443 if ((source = split_chr(arg, '@')) && /* is there a source. */
1448 if ((portno = split_chr(arg, '#')) && /* is there a port no. */
1452 if ((newlist->addr.in.sin_addr.s_addr = inet_addr(arg)) != (in_addr_t) -1)
1477 else if (inet_pton(AF_INET6, arg, &newlist->addr.in6.sin6_addr) > 0)
1524 if (!atoi_check(arg, &size))
1541 if (!atoi_check16(arg, &daemon->port))
1546 if (!atoi_check16(arg, &daemon->min_port))
1551 if (!atoi_check(arg, &daemon->ftabsize))
1557 if (arg && !atoi_check(arg, &daemon->max_logs))
1566 if (!atoi_check(arg, &i))
1573 if (!atoi_check16(arg, &daemon->query_port))
1585 if (!atoi_check(arg, &ttl))
1596 if (!atoi_check(arg, &daemon->dhcp_max))
1603 if (!atoi_check(arg, &daemon->tftp_max))
1608 daemon->tftp_prefix = opt_string_alloc(arg);
1612 if (!(comma = split(arg)) ||
1613 !atoi_check16(arg, &daemon->start_tftp_port) ||
1630 if (!(comma = split(arg)))
1636 strncpy(new->iface, arg, IF_NAMESIZE);
1642 arg = comma;
1643 comma = split(arg);
1644 if (strlen(arg) != 0)
1649 strncpy(b->iface, arg, IF_NAMESIZE);
1675 if (!arg)
1683 for (cp = arg; *cp; cp++)
1687 if (*cp != ',' && (comma = split(arg)))
1689 if (strstr(arg, "net:") == arg)
1692 tt->net = opt_string_alloc(arg+4);
1701 new->netid.net = opt_string_alloc(arg);
1703 arg = comma;
1707 a[0] = arg;
1808 if ((a[0] = arg))
1816 char *arg = a[j];
1818 if ((arg[0] == 'i' || arg[0] == 'I') &&
1819 (arg[1] == 'd' || arg[1] == 'D') &&
1820 arg[2] == ':')
1822 if (arg[3] == '*')
1827 arg += 3; /* dump id: */
1828 if (strchr(arg, ':'))
1829 len = parse_hex(arg, (unsigned char *)arg, -1, NULL, NULL);
1832 unhide_metas(arg);
1833 len = (int) strlen(arg);
1840 memcpy(new->clid, arg, len);
1844 else if (strstr(arg, "net:") == arg)
1846 int len = strlen(arg + 4) + 1;
1850 strcpy(new->netid.net, arg+4);
1941 problem = parse_dhcp_opt(arg,
1950 while (arg && strstr(arg, "net:") == arg)
1955 comma = split(arg);
1956 newid->net = opt_string_alloc(arg+4);
1957 arg = comma;
1960 if (!arg)
1966 comma = split(arg);
1967 dhcp_file = opt_string_alloc(arg);
1971 arg = comma;
1972 comma = split(arg);
1973 dhcp_sname = opt_string_alloc(arg);
2004 while (arg && strstr(arg, "net:") == arg)
2007 comma = split(arg);
2010 nn->net = opt_string_alloc(arg+4);
2011 arg = comma;
2014 if (!arg)
2018 comma = split(arg);
2019 unhide_metas(arg);
2020 new->len = strlen(arg) + 1;
2022 memcpy(new->val + 1, arg, new->len - 1);
2050 while (arg && strstr(arg, "net:") == arg)
2053 comma = split(arg);
2056 nn->net = opt_string_alloc(arg+4);
2057 arg = comma;
2060 if (arg && (comma = split(arg)))
2063 if (strcasecmp(CSA[i], arg) == 0)
2066 if (CSA[i] || atoi_check(arg, &i))
2068 arg = comma;
2069 comma = split(arg);
2072 new->menu = opt_string_alloc(arg);
2076 arg = comma;
2077 comma = split(arg);
2078 if (atoi_check(arg, &i))
2086 new->basename = opt_string_alloc(arg);
2115 if (!(comma = split(arg)))
2120 if (strstr(arg, "net:") == arg)
2121 new->netid.net = opt_string_alloc(arg+4);
2123 new->netid.net = opt_string_alloc(arg);
2138 if (!(comma = split(arg)))
2145 if (strstr(arg, "net:") == arg)
2146 new->netid.net = opt_string_alloc(arg+4);
2148 new->netid.net = opt_string_alloc(arg);
2195 if (!arg)
2202 comma = split(arg);
2203 if (!atoi_check16(arg, &daemon->dhcp_server_port) ||
2239 while (arg) {
2241 comma = split(arg);
2244 if (strstr(arg, "net:") == arg)
2245 member->net = opt_string_alloc(arg+4);
2247 member->net = opt_string_alloc(arg);
2248 arg = comma;
2266 if ((a[0] = arg))
2298 comma = split(arg);
2300 if (!comma || !(domain = canonicalise_opt(arg)))
2318 if (!(comma = split(arg)))
2322 char *alias = canonicalise_opt(arg);
2330 if (hostname_isequal(new->alias, arg))
2347 comma = split(arg);
2349 if (!(dom = canonicalise_opt(arg)) ||
2371 if ((a[0] = arg))
2404 if ((comma = split(arg)))
2449 /* ensure arg is terminated */
2453 if (!(new->name = canonicalise_opt(arg)))
2468 comma = split(arg);
2470 if (!(name = canonicalise_opt(arg)))
2475 arg = comma;
2476 comma = split(arg);
2477 if (!(target = canonicalise_opt(arg))
2482 arg = comma;
2483 comma = split(arg);
2484 if (!atoi_check16(arg, &port))
2489 arg = comma;
2490 comma = split(arg);
2491 if (!atoi_check16(arg, &priority))
2496 arg = comma;
2497 comma = split(arg);
2498 if (!atoi_check16(arg, &weight))
2536 char *p, *arg, *start, *buff = daemon->namebuff;
2651 arg = buff;
2655 arg = p+1;
2660 arg = NULL;
2678 else if (opts[i].has_arg == 0 && arg)
2680 else if (opts[i].has_arg == 1 && !arg)
2686 if (arg)
2687 for (; isspace((int)*arg); arg++);
2689 errmess = one_opt(option, arg, _("error"), nest + 1);
2784 char *errmess, *arg, *conffile = CONFFILE;
2827 arg = buff;
2830 arg = NULL;
2856 conffile = opt_string_alloc(arg);
2862 errmess = one_opt(option, arg, _("try --help"), 0);
2864 errmess = one_opt(option, arg, _("try -w"), 0);