summaryrefslogtreecommitdiffhomepage
path: root/src/dhcpv6-ia.c
diff options
context:
space:
mode:
authorHans Dedecker <dedeckeh@gmail.com>2019-02-11 15:46:29 +0100
committerHans Dedecker <dedeckeh@gmail.com>2019-02-11 15:50:56 +0100
commit671ccaabc893b53be8a1891aaf2236b657d6ce06 (patch)
tree69283ce5503f16fffed26beb599148478d4f06a3 /src/dhcpv6-ia.c
parent0db69b0b85c83fedd74ac77e850669a17c4e6617 (diff)
dhcpv6-ia: move function definitions to odhcpd.h
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
Diffstat (limited to 'src/dhcpv6-ia.c')
-rw-r--r--src/dhcpv6-ia.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/dhcpv6-ia.c b/src/dhcpv6-ia.c
index 95f4307..2820946 100644
--- a/src/dhcpv6-ia.c
+++ b/src/dhcpv6-ia.c
@@ -61,7 +61,7 @@ int dhcpv6_ia_init(void)
return 0;
}
-int dhcpv6_setup_ia_interface(struct interface *iface, bool enable)
+int dhcpv6_ia_setup_interface(struct interface *iface, bool enable)
{
if (!enable && iface->ia_assignments.next) {
struct dhcp_assignment *c;
@@ -272,7 +272,7 @@ static int send_reconf(struct dhcp_assignment *assign)
return odhcpd_send(iface->dhcpv6_event.uloop.fd, &assign->peer, &iov, 1, iface);
}
-void dhcpv6_enum_ia_addrs(struct interface *iface, struct dhcp_assignment *c,
+void dhcpv6_ia_enum_addrs(struct interface *iface, struct dhcp_assignment *c,
time_t now, dhcpv6_binding_cb_handler_t func, void *arg)
{
struct odhcpd_ipaddr *addrs = (c->managed) ? c->managed : iface->addr6;
@@ -349,7 +349,7 @@ void dhcpv6_write_ia_addr(struct in6_addr *addr, int prefix, _unused uint32_t pr
"%s/%d ", ipbuf, prefix);
}
-void dhcpv6_write_statefile(void)
+void dhcpv6_ia_write_statefile(void)
{
struct write_ctxt ctxt;
@@ -405,7 +405,7 @@ void dhcpv6_write_statefile(void)
ctxt.c->assigned, (unsigned)ctxt.c->length);
if (INFINITE_VALID(ctxt.c->valid_until) || ctxt.c->valid_until > now)
- dhcpv6_enum_ia_addrs(ctxt.iface, ctxt.c, now,
+ dhcpv6_ia_enum_addrs(ctxt.iface, ctxt.c, now,
dhcpv6_write_ia_addr, &ctxt);
ctxt.buf[ctxt.buf_idx - 1] = '\n';
@@ -770,7 +770,7 @@ static void handle_addrlist_change(struct netevent_handler_info *info)
}
}
- dhcpv6_write_statefile();
+ dhcpv6_ia_write_statefile();
}
static void reconf_timeout_cb(struct uloop_timeout *event)
@@ -1109,7 +1109,7 @@ static void dhcpv6_log(uint8_t msgtype, struct interface *iface, time_t now,
.buf_len = sizeof(leasebuf),
.buf_idx = 0 };
- dhcpv6_enum_ia_addrs(iface, a, now, dhcpv6_log_ia_addr, &ctxt);
+ dhcpv6_ia_enum_addrs(iface, a, now, dhcpv6_log_ia_addr, &ctxt);
}
syslog(LOG_WARNING, "DHCPV6 %s %s from %s on %s: %s %s", type, (is_pd) ? "IA_PD" : "IA_NA",
@@ -1157,7 +1157,7 @@ static bool dhcpv6_ia_on_link(const struct dhcpv6_ia_hdr *ia, struct dhcp_assign
return onlink;
}
-ssize_t dhcpv6_handle_ia(uint8_t *buf, size_t buflen, struct interface *iface,
+ssize_t dhcpv6_ia_handle_IAs(uint8_t *buf, size_t buflen, struct interface *iface,
const struct sockaddr_in6 *addr, const void *data, const uint8_t *end)
{
time_t now = odhcpd_time();
@@ -1446,7 +1446,7 @@ ssize_t dhcpv6_handle_ia(uint8_t *buf, size_t buflen, struct interface *iface,
break;
}
- dhcpv6_write_statefile();
+ dhcpv6_ia_write_statefile();
out:
return response_len;