summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Gwynne <dlg@cvs.openbsd.org>2019-02-14 03:27:43 +0000
committerDavid Gwynne <dlg@cvs.openbsd.org>2019-02-14 03:27:43 +0000
commitc376be26c6071a5ff78f4dc5b68fd0d50062d20c (patch)
tree279c1aeccabee5cda4424a9b1df73a8df6fb1556
parent6d3e296acf75641fb559456f3cbeaf510469d28e (diff)
use the configured route domain for the mpls tunnel when sending packets.
-rw-r--r--sys/net/if_mpe.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/net/if_mpe.c b/sys/net/if_mpe.c
index a516415de3d..e4ebe1665a9 100644
--- a/sys/net/if_mpe.c
+++ b/sys/net/if_mpe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_mpe.c,v 1.83 2019/02/14 00:49:04 dlg Exp $ */
+/* $OpenBSD: if_mpe.c,v 1.84 2019/02/14 03:27:42 dlg Exp $ */
/*
* Copyright (c) 2008 Pierre-Yves Ritschard <pyr@spootnik.org>
@@ -146,6 +146,7 @@ mpe_clone_destroy(struct ifnet *ifp)
void
mpe_start(struct ifnet *ifp)
{
+ struct mpe_softc *sc = ifp->if_softc;
struct mbuf *m;
struct sockaddr *sa;
struct sockaddr smpls = { .sa_family = AF_MPLS };
@@ -154,7 +155,7 @@ mpe_start(struct ifnet *ifp)
while ((m = ifq_dequeue(&ifp->if_snd)) != NULL) {
sa = mtod(m, struct sockaddr *);
- rt = rtalloc(sa, RT_RESOLVE, 0);
+ rt = rtalloc(sa, RT_RESOLVE, sc->sc_rdomain);
if (!rtisvalid(rt)) {
m_freem(m);
rtfree(rt);