Define ``rt_ifidx'' as rt_ifp->if_index to ease the transtion towards
authormpi <mpi@openbsd.org>
Sat, 24 Oct 2015 11:47:07 +0000 (11:47 +0000)
committermpi <mpi@openbsd.org>
Sat, 24 Oct 2015 11:47:07 +0000 (11:47 +0000)
getting rid of interface pointers in route entries.

ok bluhm@

sys/net/route.h

index 1b698fb..b4bf763 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: route.h,v 1.115 2015/10/07 10:50:35 mpi Exp $ */
+/*     $OpenBSD: route.h,v 1.116 2015/10/24 11:47:07 mpi Exp $ */
 /*     $NetBSD: route.h,v 1.9 1996/02/13 22:00:49 christos Exp $       */
 
 /*
@@ -103,6 +103,7 @@ struct rtentry {
 #endif
        struct sockaddr *rt_gateway;    /* value */
        struct ifnet    *rt_ifp;        /* the answer: interface to use */
+#define rt_ifidx rt_ifp->if_index
        struct ifaddr   *rt_ifa;        /* the answer: interface addr to use */
        caddr_t          rt_llinfo;     /* pointer to link level info cache or
                                           to an MPLS structure */