af_mpls: add null dev check in find_outdev
authorRoopa Prabhu <roopa@cumulusnetworks.com>
Tue, 4 Aug 2015 13:36:24 +0000 (06:36 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 7 Aug 2015 05:03:58 +0000 (22:03 -0700)
commit3dcb615e6841eb945a49f605743a6923ed591400
treec12c22a5ce9e0d80d208c9a4dfbee79754ca24cb
parent3c621818404bbb0bed1a8892d843b499182fa7e9
af_mpls: add null dev check in find_outdev

This patch adds null dev check for the 'cfg->rc_via_table ==
NEIGH_LINK_TABLE or dev_get_by_index() failed' case

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/mpls/af_mpls.c