/external/dhcpcd/ |
bind.c | 54 /* We do things after aquiring the lease, so ensure we have enough time for them */ 126 struct dhcp_lease *lease = &state->lease; local 134 get_monotonic(&lease->boundtime); 140 get_lease(lease, state->new); 143 iface->name, inet_ntoa(lease->addr)); 144 lease->leasetime = ~0U; 145 lease->net.s_addr = ifo->req_mask.s_addr; 149 iface->name, inet_ntoa(lease->addr)); 150 lease->leasetime = ~0U [all...] |
dhcpcd.h | 70 struct dhcp_lease lease; member in struct:if_state
|
showlease.c | 306 void showlease(struct dhcp_lease *lease) 308 printf("addr: %s\n", inet_ntoa(lease->addr)); 309 printf("net: %s\n", inet_ntoa(lease->net)); 310 printf("leasetime: %d\n", lease->leasetime); 311 printf("renew: %d\n", lease->renewaltime); 312 printf("rebind: %d\n", lease->rebindtime); 313 printf("server: %s\n", inet_ntoa(lease->server)); 321 struct dhcp_lease *lease; local 330 fprintf(stderr, "Couldn't read lease file: %s\n", strerror(errno)); 333 lease = malloc(sizeof(*lease)) [all...] |
configure.c | 721 struct dhcp_lease *lease = &iface->state->lease; local 741 !has_address(iface->name, &lease->addr, &lease->net)) 744 iface->name, inet_ntoa(lease->addr), 745 inet_ntocidr(lease->net)); 747 &lease->addr, &lease->net, &lease->brd) == -1 && 756 if (iface->addr.s_addr != lease->addr.s_addr & [all...] |
dhcp.c | 844 const struct dhcp_lease *lease = &iface->state->lease; local 852 iface->net.s_addr == lease->net.s_addr && 859 dhcp->ciaddr = lease->addr.s_addr; 897 if (lease->addr.s_addr && lease->cookie == htonl(MAGIC_COOKIE)) { 900 lease->addr.s_addr != iface->addr.s_addr)) 902 PUTADDR(DHO_IPADDRESS, lease->addr); 903 if (lease->server.s_addr) 904 PUTADDR(DHO_SERVERID, lease->server) [all...] |
client.c | 134 struct dhcp_lease lease; member in struct:if_state 363 get_lease(struct dhcp_lease *lease, const struct dhcp_message *dhcp) 367 if (lease->frominfo) 369 lease->addr.s_addr = dhcp->yiaddr; 371 if (get_option_addr(&lease->net, dhcp, DHO_SUBNETMASK) == -1) 372 lease->net.s_addr = get_netmask(dhcp->yiaddr); 373 if (get_option_uint32(&lease->leasetime, dhcp, DHO_LEASETIME) == 0) { 374 /* Ensure that we can use the lease */ 376 if (t + (time_t)lease->leasetime < t) { 377 logger(LOG_WARNING, "lease of %u would overflow, 393 struct dhcp_lease *lease = &state->lease; local 465 struct dhcp_lease *lease = &state->lease; local 863 struct dhcp_lease *lease = &state->lease; local 907 struct dhcp_lease *lease = &state->lease; local 1015 struct dhcp_lease *lease = &state->lease; local 1130 struct dhcp_lease *lease = &state->lease; local 1381 struct dhcp_lease *lease = &state->lease; local [all...] |
dhcpcd.c | 235 iface->state->lease.addr.s_addr = 0; 327 * Also, we should not unicast from a BOOTP lease. */ 339 to.s_addr = state->lease.server.s_addr; 412 iface->state->lease.addr.s_addr = 0; 417 syslog(LOG_ERR, "%s: lease expired", iface->name); 493 struct dhcp_lease *lease = &state->lease; local 548 lease->frominfo = 0; 549 lease->addr.s_addr = dhcp->yiaddr; 550 lease->cookie = dhcp->cookie [all...] |
/frameworks/base/core/jni/ |
android_net_NetUtils.cpp | 38 uint32_t *lease); 47 uint32_t *lease); 118 uint32_t lease; local 125 dns1, dns2, server, &lease); 128 dns1, dns2, server, &lease); 163 env->SetIntField(info, dhcpInfoInternalFieldIds.leaseDuration, lease);
|
/external/dnsmasq/contrib/wrt/ |
dhcp_lease_time.c | 16 and print (to stdout) the time remaining in any lease for the given 19 If an error occurs or no lease exists for the given address, 136 struct in_addr lease; local 155 lease.s_addr = inet_addr(argv[1]); 163 packet.ciaddr = lease; 213 return 1; /* no lease */
|
dhcp_release.c | 17 to tell the local DHCP server to delete a particular lease. 31 for ethernet. This encoding is the one used in dnsmasq lease files. 250 struct in_addr server, lease; local 285 lease.s_addr = inet_addr(argv[2]); 286 server = find_interface(lease, nl, if_nametoindex(argv[1])); 297 packet.ciaddr = lease;
|
/external/dnsmasq/src/ |
lease.c | 28 struct dhcp_lease *lease; local 44 lease database. */ 66 die(_("cannot open or create lease file %s: %s"), daemon->lease_file, EC_FILE); 91 if (!(lease = lease_allocate(addr))) 96 lease->expires = (time_t)ei + now; 98 lease->expires = (time_t)0; 99 lease->length = ei; 103 lease->expires = (time_t)ei; 106 lease_set_hwaddr(lease, (unsigned char *)daemon->dhcp_buff2, (unsigned char *)daemon->packet, hw_len, hw_type, clid_len); 109 lease_set_hostname(lease, daemon->dhcp_buff, 0) 149 struct dhcp_lease *lease; local 175 struct dhcp_lease *lease; local 245 struct dhcp_lease *lease; local 266 struct dhcp_lease *lease, *tmp, **up; local 295 struct dhcp_lease *lease; local 316 struct dhcp_lease *lease; local 328 struct dhcp_lease *lease; local 518 struct dhcp_lease *lease; local 531 struct dhcp_lease *lease; local [all...] |
rfc2131.c | 125 struct dhcp_lease *ltmp, *lease = NULL; local 258 /* do we have a lease in store? */ 259 lease = lease_find_by_client(mess->chaddr, mess->hlen, mess->htype, clid, clid_len); 263 if (lease && !clid && lease->clid) 265 clid_len = lease->clid_len; 266 clid = lease->clid; 286 use the ciaddr. This is necessary because a machine which got a lease via a 429 if ((lease = lease_find_by_addr(config->addr)) && 430 (lease->hwaddr_len != mess->hlen | [all...] |
/system/core/libnetutils/ |
dhcpclient.c | 111 uint32_t lease; member in struct:dhcp_info 118 uint32_t *lease) 126 *lease = last_good_info.lease; 161 LOGD("server %s, lease %d seconds", 162 ipaddr(info->serveraddr), info->lease); 211 memcpy(&info->lease, x, 4); 212 info->lease = ntohl(info->lease);
|