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

Function carp_ifa_addroute

freebsd/netinet/ip_carp.c:1061–1081  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1059}
1060
1061static void
1062carp_ifa_addroute(struct ifaddr *ifa)
1063{
1064
1065 switch (ifa->ifa_addr->sa_family) {
1066#ifdef INET
1067 case AF_INET:
1068 in_addprefix(ifatoia(ifa));
1069 ifa_add_loopback_route(ifa,
1070 (struct sockaddr *)&ifatoia(ifa)->ia_addr);
1071 break;
1072#endif
1073#ifdef INET6
1074 case AF_INET6:
1075 ifa_add_loopback_route(ifa,
1076 (struct sockaddr *)&ifatoia6(ifa)->ia_addr);
1077 nd6_add_ifa_lle(ifatoia6(ifa));
1078 break;
1079#endif
1080 }
1081}
1082
1083static void
1084carp_delroute(struct carp_softc *sc)

Callers 1

carp_addrouteFunction · 0.85

Calls 3

in_addprefixFunction · 0.85
ifa_add_loopback_routeFunction · 0.85
nd6_add_ifa_lleFunction · 0.85

Tested by

no test coverage detected