Move up fibnum to ensure it is always defined.

Found by:	ian
MFC with:	r264987
This commit is contained in:
Alexander V. Chernikov 2014-04-27 02:20:09 +00:00
parent 7ff9cf1d06
commit f5d9a6964d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=264998

View File

@ -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