diff options
Diffstat (limited to 'net/xfrm/xfrm_policy.c')
-rw-r--r-- | net/xfrm/xfrm_policy.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/xfrm/xfrm_policy.c b/net/xfrm/xfrm_policy.c index 6e97855b5842..65bd1ca51517 100644 --- a/net/xfrm/xfrm_policy.c +++ b/net/xfrm/xfrm_policy.c | |||
@@ -1353,8 +1353,9 @@ static inline struct xfrm_dst *xfrm_alloc_dst(struct net *net, int family) | |||
1353 | xdst = dst_alloc(dst_ops, NULL, 0, 0, 0); | 1353 | xdst = dst_alloc(dst_ops, NULL, 0, 0, 0); |
1354 | 1354 | ||
1355 | if (likely(xdst)) { | 1355 | if (likely(xdst)) { |
1356 | memset(&xdst->u.rt6.rt6i_table, 0, | 1356 | struct dst_entry *dst = &xdst->u.dst; |
1357 | sizeof(*xdst) - sizeof(struct dst_entry)); | 1357 | |
1358 | memset(dst + 1, 0, sizeof(*xdst) - sizeof(*dst)); | ||
1358 | xdst->flo.ops = &xfrm_bundle_fc_ops; | 1359 | xdst->flo.ops = &xfrm_bundle_fc_ops; |
1359 | } else | 1360 | } else |
1360 | xdst = ERR_PTR(-ENOBUFS); | 1361 | xdst = ERR_PTR(-ENOBUFS); |