MCPcopy Create free account
hub / github.com/F-Stack/f-stack / in6_get_unicast_scopeid

Function in6_get_unicast_scopeid

freebsd/netinet6/scope6.c:474–481  ·  view source on GitHub ↗

* Returns scope zone id for the unicast address @in6. * * Returns 0 for global unicast and loopback addresses. * Returns interface index for the link-local addresses. */

Source from the content-addressed store, hash-verified

472 * Returns interface index for the link-local addresses.
473 */
474uint32_t
475in6_get_unicast_scopeid(const struct in6_addr *in6, const struct ifnet *ifp)
476{
477
478 if (IN6_IS_SCOPE_LINKLOCAL(in6))
479 return (ifp->if_index);
480 return (0);
481}
482
483void
484in6_set_unicast_scopeid(struct in6_addr *in6, uint32_t scopeid)

Callers 1

ip6_forwardFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected