Lines Matching refs:daemon

592   r->next = daemon->txt;  in add_txt()
593 daemon->txt = r; in add_txt()
967 new->next = daemon->dhcp_match; in parse_dhcp_opt()
968 daemon->dhcp_match = new; in parse_dhcp_opt()
973 new->next = daemon->dhcp_opts; in parse_dhcp_opt()
974 daemon->dhcp_opts = new; in parse_dhcp_opt()
1015 daemon->options |= rept; in one_opt()
1116 daemon->log_file = opt_string_alloc(arg); in one_opt()
1127 daemon->log_fac = facilitynames[i].c_val; in one_opt()
1135 daemon->runfile = opt_string_alloc(arg); in one_opt()
1139 if (daemon->dhcp_hosts_file) in one_opt()
1142 daemon->dhcp_hosts_file = opt_string_alloc(arg); in one_opt()
1146 if (daemon->dhcp_opts_file) in one_opt()
1149 daemon->dhcp_opts_file = opt_string_alloc(arg); in one_opt()
1155 struct resolvc *new, *list = daemon->resolv_files; in one_opt()
1178 daemon->resolv_files = list; in one_opt()
1200 new->next = daemon->mxnames; in one_opt()
1201 daemon->mxnames = new; in one_opt()
1210 if (!(daemon->mxtarget = canonicalise_opt(arg))) in one_opt()
1216 daemon->lease_file = opt_string_alloc(arg); in one_opt()
1225 daemon->lease_change_command = opt_string_alloc(arg); in one_opt()
1237 new->next = daemon->addn_hosts; in one_opt()
1238 daemon->addn_hosts = new; in one_opt()
1244 daemon->options |= OPT_RESOLV_DOMAIN; in one_opt()
1280 new->next = daemon->cond_domain; in one_opt()
1281 daemon->cond_domain = new; in one_opt()
1284 daemon->domain_suffix = d; in one_opt()
1290 daemon->username = opt_string_alloc(arg); in one_opt()
1294 daemon->groupname = opt_string_alloc(arg); in one_opt()
1295 daemon->group_set = 1; in one_opt()
1300 daemon->scriptuser = opt_string_alloc(arg); in one_opt()
1308 new->next = daemon->if_names; in one_opt()
1309 daemon->if_names = new; in one_opt()
1326 new->next = daemon->if_except; in one_opt()
1327 daemon->if_except = new; in one_opt()
1331 new->next = daemon->dhcp_except; in one_opt()
1332 daemon->dhcp_except = new; in one_opt()
1345 baddr->next = daemon->bogus_addr; in one_opt()
1346 daemon->bogus_addr = baddr; in one_opt()
1359 new->next = daemon->if_addrs; in one_opt()
1368 daemon->if_addrs = new; in one_opt()
1503 serv->next = daemon->servers; in one_opt()
1504 daemon->servers = newlist; in one_opt()
1523 daemon->cachesize = size; in one_opt()
1529 if (!atoi_check16(arg, &daemon->port)) in one_opt()
1534 if (!atoi_check16(arg, &daemon->min_port)) in one_opt()
1539 if (!atoi_check(arg, &daemon->ftabsize)) in one_opt()
1544 daemon->max_logs = LOG_MAX; /* default */ in one_opt()
1545 if (arg && !atoi_check(arg, &daemon->max_logs)) in one_opt()
1547 else if (daemon->max_logs > 100) in one_opt()
1548 daemon->max_logs = 100; in one_opt()
1556 daemon->edns_pktsz = (unsigned short)i; in one_opt()
1561 if (!atoi_check16(arg, &daemon->query_port)) in one_opt()
1565 if (daemon->query_port == 0) in one_opt()
1566 daemon->osport = 1; in one_opt()
1576 daemon->neg_ttl = (unsigned long)ttl; in one_opt()
1578 daemon->local_ttl = (unsigned long)ttl; in one_opt()
1584 if (!atoi_check(arg, &daemon->dhcp_max)) in one_opt()
1591 if (!atoi_check(arg, &daemon->tftp_max)) in one_opt()
1596 daemon->tftp_prefix = opt_string_alloc(arg); in one_opt()
1601 !atoi_check16(arg, &daemon->start_tftp_port) || in one_opt()
1602 !atoi_check16(comma, &daemon->end_tftp_port)) in one_opt()
1605 if (daemon->start_tftp_port > daemon->end_tftp_port) in one_opt()
1607 int tmp = daemon->start_tftp_port; in one_opt()
1608 daemon->start_tftp_port = daemon->end_tftp_port; in one_opt()
1609 daemon->end_tftp_port = tmp; in one_opt()
1626 new->next = daemon->bridges; in one_opt()
1627 daemon->bridges = new; in one_opt()
1651 new->next = daemon->dhcp; in one_opt()
1734 daemon->dhcp = new; in one_opt()
1792 new->next = daemon->dhcp_conf; in one_opt()
1921 daemon->dhcp_conf = new; in one_opt()
1976 new->next = daemon->boot_config; in one_opt()
1977 daemon->boot_config = new; in one_opt()
2020 new->next = daemon->dhcp_opts; in one_opt()
2021 daemon->dhcp_opts = new; in one_opt()
2022 daemon->enable_pxe = 1; in one_opt()
2082 if (!daemon->pxe_services) in one_opt()
2083 daemon->pxe_services = new; in one_opt()
2087 for (s = daemon->pxe_services; s->next; s = s->next); in one_opt()
2091 daemon->enable_pxe = 1; in one_opt()
2114 new->next = daemon->dhcp_macs; in one_opt()
2115 daemon->dhcp_macs = new; in one_opt()
2176 new->next = daemon->dhcp_vendors; in one_opt()
2177 daemon->dhcp_vendors = new; in one_opt()
2185 daemon->dhcp_server_port = DHCP_SERVER_ALTPORT; in one_opt()
2186 daemon->dhcp_client_port = DHCP_CLIENT_ALTPORT; in one_opt()
2191 if (!atoi_check16(arg, &daemon->dhcp_server_port) || in one_opt()
2192 (comma && !atoi_check16(comma, &daemon->dhcp_client_port))) in one_opt()
2195 daemon->dhcp_client_port = daemon->dhcp_server_port+1; in one_opt()
2208 new->next = daemon->dhcp_ignore; in one_opt()
2209 daemon->dhcp_ignore = new; in one_opt()
2213 new->next = daemon->force_broadcast; in one_opt()
2214 daemon->force_broadcast = new; in one_opt()
2218 new->next = daemon->bootp_dynamic; in one_opt()
2219 daemon->bootp_dynamic = new; in one_opt()
2223 new->next = daemon->dhcp_ignore_names; in one_opt()
2224 daemon->dhcp_ignore_names = new; in one_opt()
2249 new->next = daemon->doctors; in one_opt()
2250 daemon->doctors = new; in one_opt()
2295 for (up = &daemon->int_names; *up; up = &((*up)->next)); in one_opt()
2317 for (new = daemon->cnames; new; new = new->next) in one_opt()
2321 new->next = daemon->cnames; in one_opt()
2322 daemon->cnames = new; in one_opt()
2343 new->next = daemon->ptr; in one_opt()
2344 daemon->ptr = new; in one_opt()
2374 new->next = daemon->naptr; in one_opt()
2375 daemon->naptr = new; in one_opt()
2421 new->next = daemon->txt; in one_opt()
2422 daemon->txt = new; in one_opt()
2494 new->next = daemon->mxnames; in one_opt()
2495 daemon->mxnames = new; in one_opt()
2511 daemon->listen_mark = mark; in one_opt()
2514 my_syslog(LOG_WARNING, "daemon->listen_mark: 0x%x, *endptr=%d", daemon->listen_mark, *endptr); in one_opt()
2537 char *p, *arg, *start, *buff = daemon->namebuff; in one_file()
2711 if (daemon->dhcp_hosts_file) in reread_dhcp()
2716 for (up = &daemon->dhcp_conf, configs = daemon->dhcp_conf; configs; configs = cp) in reread_dhcp()
2744 one_file(daemon->dhcp_hosts_file, 1, LOPT_BANK); in reread_dhcp()
2745 my_syslog(MS_DHCP | LOG_INFO, _("read %s"), daemon->dhcp_hosts_file); in reread_dhcp()
2748 if (daemon->dhcp_opts_file) in reread_dhcp()
2753 for (up = &daemon->dhcp_opts, opts = daemon->dhcp_opts; opts; opts = cp) in reread_dhcp()
2775 one_file(daemon->dhcp_opts_file, 1, LOPT_OPTS); in reread_dhcp()
2776 my_syslog(MS_DHCP | LOG_INFO, _("read %s"), daemon->dhcp_opts_file); in reread_dhcp()
2789 daemon = opt_malloc(sizeof(struct daemon)); in read_opts()
2790 memset(daemon, 0, sizeof(struct daemon)); in read_opts()
2791 daemon->namebuff = buff; in read_opts()
2794 daemon->cachesize = CACHESIZ; in read_opts()
2795 daemon->ftabsize = FTABSIZ; in read_opts()
2796 daemon->port = NAMESERVER_PORT; in read_opts()
2797 daemon->dhcp_client_port = DHCP_CLIENT_PORT; in read_opts()
2798 daemon->dhcp_server_port = DHCP_SERVER_PORT; in read_opts()
2799 daemon->default_resolv.is_default = 1; in read_opts()
2800 daemon->default_resolv.name = RESOLVFILE; in read_opts()
2801 daemon->resolv_files = &daemon->default_resolv; in read_opts()
2802 daemon->username = CHUSER; in read_opts()
2803 daemon->runfile = RUNFILE; in read_opts()
2804 daemon->dhcp_max = MAXLEASES; in read_opts()
2805 daemon->tftp_max = TFTP_MAX_CONNECTIONS; in read_opts()
2806 daemon->edns_pktsz = EDNS_PKTSZ; in read_opts()
2807 daemon->log_fac = -1; in read_opts()
2876 if (daemon->servers) in read_opts()
2879 for (tmp = daemon->servers; tmp; tmp = tmp->next) in read_opts()
2883 tmp->source_addr.in.sin_port = htons(daemon->query_port); in read_opts()
2886 tmp->source_addr.in6.sin6_port = htons(daemon->query_port); in read_opts()
2891 if (daemon->if_addrs) in read_opts()
2894 for(tmp = daemon->if_addrs; tmp; tmp = tmp->next) in read_opts()
2896 tmp->addr.in.sin_port = htons(daemon->port); in read_opts()
2899 tmp->addr.in6.sin6_port = htons(daemon->port); in read_opts()
2904 if ((daemon->options & OPT_LOCALMX) || daemon->mxnames || daemon->mxtarget) in read_opts()
2911 for (mx = daemon->mxnames; mx; mx = mx->next) in read_opts()
2915 if ((daemon->mxtarget || (daemon->options & OPT_LOCALMX)) && !mx) in read_opts()
2918 mx->next = daemon->mxnames; in read_opts()
2922 daemon->mxnames = mx; in read_opts()
2925 if (!daemon->mxtarget) in read_opts()
2926 daemon->mxtarget = opt_string_alloc(buff); in read_opts()
2928 for (mx = daemon->mxnames; mx; mx = mx->next) in read_opts()
2930 mx->target = daemon->mxtarget; in read_opts()
2933 if (!(daemon->options & OPT_NO_RESOLV) && in read_opts()
2934 daemon->resolv_files && in read_opts()
2935 daemon->resolv_files->next && in read_opts()
2936 (daemon->options & OPT_NO_POLL)) in read_opts()
2939 if (daemon->options & OPT_RESOLV_DOMAIN) in read_opts()
2944 if ((daemon->options & OPT_NO_RESOLV) || in read_opts()
2945 !daemon->resolv_files || in read_opts()
2946 (daemon->resolv_files)->next) in read_opts()
2949 if (!(f = fopen((daemon->resolv_files)->name, "r"))) in read_opts()
2950 die(_("failed to read %s: %s"), (daemon->resolv_files)->name, EC_FILE); in read_opts()
2960 (daemon->domain_suffix = canonicalise_opt(token))) in read_opts()
2966 if (!daemon->domain_suffix) in read_opts()
2967 die(_("no search directive found in %s"), (daemon->resolv_files)->name, EC_MISC); in read_opts()
2970 if (daemon->domain_suffix) in read_opts()
2975 for (srv = daemon->mxnames; srv; srv = srv->next) in read_opts()
2982 strcat(buff, daemon->domain_suffix); in read_opts()
2987 else if (daemon->options & OPT_DHCP_FQDN) in read_opts()