From f5d9a6964dffc3c86c3d95370518c8d8078d655a Mon Sep 17 00:00:00 2001 From: "Alexander V. Chernikov" Date: Sun, 27 Apr 2014 02:20:09 +0000 Subject: [PATCH] Move up fibnum to ensure it is always defined. Found by: ian MFC with: r264987 --- sys/net/rtsock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index 9a32969f0cc2..626dc8fbab10 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -531,6 +531,8 @@ route_output(struct mbuf *m, struct socket *so) union sockaddr_union saun; sa_family_t saf = AF_UNSPEC; + fibnum = so->so_fibnum; + #define senderr(e) { error = e; goto flush;} if (m == NULL || ((m->m_len < sizeof(long)) && (m = m_pullup(m, sizeof(long))) == NULL)) @@ -582,8 +584,6 @@ route_output(struct mbuf *m, struct socket *so) senderr(error); } - fibnum = so->so_fibnum; - /* * The given gateway address may be an interface address. * For example, issuing a "route change" command on a route