From 4e5ca364f4f8dadb90ec7cdb7db160dbd3b30966 Mon Sep 17 00:00:00 2001 From: Tom Gundersen Date: Wed, 21 Oct 2015 02:14:24 +0200 Subject: sd-ndisc: drop sd_ndisc_get_prefixlen() This is unused, and in the future we will pass prefixes and prefixlengths directly to the callbacks when needed rather than having to search for them. --- src/libsystemd-network/sd-ndisc.c | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'src/libsystemd-network/sd-ndisc.c') diff --git a/src/libsystemd-network/sd-ndisc.c b/src/libsystemd-network/sd-ndisc.c index 2df952e04c..fd512b5ce4 100644 --- a/src/libsystemd-network/sd-ndisc.c +++ b/src/libsystemd-network/sd-ndisc.c @@ -316,24 +316,6 @@ static int ndisc_prefix_match(sd_ndisc *nd, const struct in6_addr *addr, return -EADDRNOTAVAIL; } -int sd_ndisc_get_prefixlen(sd_ndisc *nd, const struct in6_addr *addr, - uint8_t *prefixlen) { - int r; - NDiscPrefix *prefix; - - assert_return(nd, -EINVAL); - assert_return(addr, -EINVAL); - assert_return(prefixlen, -EINVAL); - - r = ndisc_prefix_match(nd, addr, sizeof(addr->s6_addr) * 8, &prefix); - if (r < 0) - return r; - - *prefixlen = prefix->len; - - return 0; -} - static int ndisc_prefix_update(sd_ndisc *nd, ssize_t len, const struct nd_opt_prefix_info *prefix_opt) { NDiscPrefix *prefix; -- cgit v1.2.3-54-g00ecf