diff options
Diffstat (limited to 'net/ipv4/ipmr.c')
-rw-r--r-- | net/ipv4/ipmr.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c index 0518a4fb177b..dcf4d7fe3917 100644 --- a/net/ipv4/ipmr.c +++ b/net/ipv4/ipmr.c | |||
@@ -2120,15 +2120,16 @@ static int ipmr_fill_mroute(struct mr_table *mrt, struct sk_buff *skb, | |||
2120 | rtm->rtm_src_len = 32; | 2120 | rtm->rtm_src_len = 32; |
2121 | rtm->rtm_tos = 0; | 2121 | rtm->rtm_tos = 0; |
2122 | rtm->rtm_table = mrt->id; | 2122 | rtm->rtm_table = mrt->id; |
2123 | NLA_PUT_U32(skb, RTA_TABLE, mrt->id); | 2123 | if (nla_put_u32(skb, RTA_TABLE, mrt->id)) |
2124 | goto nla_put_failure; | ||
2124 | rtm->rtm_type = RTN_MULTICAST; | 2125 | rtm->rtm_type = RTN_MULTICAST; |
2125 | rtm->rtm_scope = RT_SCOPE_UNIVERSE; | 2126 | rtm->rtm_scope = RT_SCOPE_UNIVERSE; |
2126 | rtm->rtm_protocol = RTPROT_UNSPEC; | 2127 | rtm->rtm_protocol = RTPROT_UNSPEC; |
2127 | rtm->rtm_flags = 0; | 2128 | rtm->rtm_flags = 0; |
2128 | 2129 | ||
2129 | NLA_PUT_BE32(skb, RTA_SRC, c->mfc_origin); | 2130 | if (nla_put_be32(skb, RTA_SRC, c->mfc_origin) || |
2130 | NLA_PUT_BE32(skb, RTA_DST, c->mfc_mcastgrp); | 2131 | nla_put_be32(skb, RTA_DST, c->mfc_mcastgrp)) |
2131 | 2132 | goto nla_put_failure; | |
2132 | if (__ipmr_fill_mroute(mrt, skb, c, rtm) < 0) | 2133 | if (__ipmr_fill_mroute(mrt, skb, c, rtm) < 0) |
2133 | goto nla_put_failure; | 2134 | goto nla_put_failure; |
2134 | 2135 | ||