diff options
author | Denys Vlasenko | 2009-06-16 10:23:01 +0200 |
---|---|---|
committer | Denys Vlasenko | 2009-06-16 10:23:01 +0200 |
commit | 1d924f59b1854e9638c63a743642e63c1bef38b9 (patch) | |
tree | 9cee2a7da051fb217fb610e7509d5dfd3657da47 /networking/udhcp/files.c | |
parent | 47f2d7ef7d4dbeea19a55f9d73ef826f9d06650f (diff) | |
download | busybox-1d924f59b1854e9638c63a743642e63c1bef38b9.zip busybox-1d924f59b1854e9638c63a743642e63c1bef38b9.tar.gz |
udhcp: rename fields in struct dhcpOfferedAddr
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/udhcp/files.c')
-rw-r--r-- | networking/udhcp/files.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/networking/udhcp/files.c b/networking/udhcp/files.c index af77308..671ea94 100644 --- a/networking/udhcp/files.c +++ b/networking/udhcp/files.c @@ -360,7 +360,7 @@ void FAST_FUNC write_leases(void) for (i = 0; i < server_config.max_leases; i++) { leasetime_t tmp_time; - if (leases[i].yiaddr == 0) + if (leases[i].lease_nip == 0) continue; /* Screw with the time in the struct, for easier writing */ @@ -413,14 +413,14 @@ void FAST_FUNC read_leases(const char *file) IF_UDHCP_DEBUG(i = 0;) while (full_read(fd, &lease, sizeof(lease)) == sizeof(lease)) { /* ADDME: what if it matches some static lease? */ - uint32_t y = ntohl(lease.yiaddr); + uint32_t y = ntohl(lease.lease_nip); if (y >= server_config.start_ip && y <= server_config.end_ip) { signed_leasetime_t expires = ntohl(lease.expires) - (signed_leasetime_t)time_passed; if (expires <= 0) continue; /* NB: add_lease takes "relative time", IOW, * lease duration, not lease deadline. */ - if (!(add_lease(lease.chaddr, lease.yiaddr, expires, lease.hostname))) { + if (!(add_lease(lease.lease_mac16, lease.lease_nip, expires, lease.hostname))) { bb_error_msg("too many leases while loading %s", file); break; } |