8c0fec805f
rather than pointers, requiring callers to properly dispose of those references. The following routines now return references: ifaddr_byindex ifa_ifwithaddr ifa_ifwithbroadaddr ifa_ifwithdstaddr ifa_ifwithnet ifaof_ifpforaddr ifa_ifwithroute ifa_ifwithroute_fib rt_getifa rt_getifa_fib IFP_TO_IA ip_rtaddr in6_ifawithifp in6ifa_ifpforlinklocal in6ifa_ifpwithaddr in6_ifadd carp_iamatch6 ip6_getdstifaddr Remove unused macro which didn't have required referencing: IFP_TO_IA6 This closes many small races in which changes to interface or address lists while an ifaddr was in use could lead to use of freed memory (etc). In a few cases, add missing if_addr_list locking required to safely acquire references. Because of a lack of deep copying support, we accept a race in which an in6_ifaddr pointed to by mbuf tags and extracted with ip6_getdstifaddr() doesn't hold a reference while in transmit. Once we have mbuf tag deep copy support, this can be fixed. Reviewed by: bz Obtained from: Apple, Inc. (portions) MFC after: 6 weeks (portions) |
||
---|---|---|
.. | ||
_ieee80211.h | ||
ieee80211_acl.c | ||
ieee80211_adhoc.c | ||
ieee80211_adhoc.h | ||
ieee80211_amrr.c | ||
ieee80211_amrr.h | ||
ieee80211_crypto_ccmp.c | ||
ieee80211_crypto_none.c | ||
ieee80211_crypto_tkip.c | ||
ieee80211_crypto_wep.c | ||
ieee80211_crypto.c | ||
ieee80211_crypto.h | ||
ieee80211_ddb.c | ||
ieee80211_dfs.c | ||
ieee80211_dfs.h | ||
ieee80211_freebsd.c | ||
ieee80211_freebsd.h | ||
ieee80211_hostap.c | ||
ieee80211_hostap.h | ||
ieee80211_ht.c | ||
ieee80211_ht.h | ||
ieee80211_input.c | ||
ieee80211_input.h | ||
ieee80211_ioctl.c | ||
ieee80211_ioctl.h | ||
ieee80211_monitor.c | ||
ieee80211_monitor.h | ||
ieee80211_node.c | ||
ieee80211_node.h | ||
ieee80211_output.c | ||
ieee80211_phy.c | ||
ieee80211_phy.h | ||
ieee80211_power.c | ||
ieee80211_power.h | ||
ieee80211_proto.c | ||
ieee80211_proto.h | ||
ieee80211_radiotap.c | ||
ieee80211_radiotap.h | ||
ieee80211_regdomain.c | ||
ieee80211_regdomain.h | ||
ieee80211_rssadapt.c | ||
ieee80211_rssadapt.h | ||
ieee80211_scan_sta.c | ||
ieee80211_scan.c | ||
ieee80211_scan.h | ||
ieee80211_sta.c | ||
ieee80211_sta.h | ||
ieee80211_superg.c | ||
ieee80211_superg.h | ||
ieee80211_tdma.c | ||
ieee80211_tdma.h | ||
ieee80211_var.h | ||
ieee80211_wds.c | ||
ieee80211_wds.h | ||
ieee80211_xauth.c | ||
ieee80211.c | ||
ieee80211.h |