]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/netinet/in_pcb.h
xnu-3248.20.55.tar.gz
[apple/xnu.git] / bsd / netinet / in_pcb.h
index 7ce89307aa027fb252aec700cf74af24f192fedd..8616581768fabce45d9833b518530cabe019ec84 100644 (file)
@@ -498,6 +498,15 @@ struct     xinpgen {
 #if IPSEC
 #define        in6p_sp         inp_sp
 #endif /* IPSEC */
+#define INP_INC_IFNET_STAT(_inp_, _stat_) { \
+       if ((_inp_)->inp_last_outifp != NULL) { \
+               if ((_inp_)->inp_vflag & INP_IPV6) { \
+                       (_inp_)->inp_last_outifp->if_ipv6_stat->_stat_++;\
+               } else { \
+                       (_inp_)->inp_last_outifp->if_ipv4_stat->_stat_++;\
+               }\
+       }\
+}
 
 struct inpcbport {
        LIST_ENTRY(inpcbport) phd_hash;