diff options
Diffstat (limited to 'net/xfrm/xfrm_user.c')
-rw-r--r-- | net/xfrm/xfrm_user.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c index bd8e6882c08..4d3237d08ff 100644 --- a/net/xfrm/xfrm_user.c +++ b/net/xfrm/xfrm_user.c | |||
@@ -900,7 +900,7 @@ static int xfrm_flush_sa(struct sk_buff *skb, struct nlmsghdr *nlh, void **xfrma | |||
900 | struct xfrm_usersa_flush *p = NLMSG_DATA(nlh); | 900 | struct xfrm_usersa_flush *p = NLMSG_DATA(nlh); |
901 | 901 | ||
902 | xfrm_state_flush(p->proto); | 902 | xfrm_state_flush(p->proto); |
903 | c.data = p->proto; | 903 | c.data.proto = p->proto; |
904 | c.event = XFRM_SAP_FLUSHED; | 904 | c.event = XFRM_SAP_FLUSHED; |
905 | c.seq = nlh->nlmsg_seq; | 905 | c.seq = nlh->nlmsg_seq; |
906 | c.pid = nlh->nlmsg_pid; | 906 | c.pid = nlh->nlmsg_pid; |
@@ -1129,14 +1129,13 @@ nlmsg_failure: | |||
1129 | static int xfrm_exp_state_notify(struct xfrm_state *x, struct km_event *c) | 1129 | static int xfrm_exp_state_notify(struct xfrm_state *x, struct km_event *c) |
1130 | { | 1130 | { |
1131 | struct sk_buff *skb; | 1131 | struct sk_buff *skb; |
1132 | int hard = c ->data; | ||
1133 | 1132 | ||
1134 | /* fix to do alloc using NLM macros */ | 1133 | /* fix to do alloc using NLM macros */ |
1135 | skb = alloc_skb(sizeof(struct xfrm_user_expire) + 16, GFP_ATOMIC); | 1134 | skb = alloc_skb(sizeof(struct xfrm_user_expire) + 16, GFP_ATOMIC); |
1136 | if (skb == NULL) | 1135 | if (skb == NULL) |
1137 | return -ENOMEM; | 1136 | return -ENOMEM; |
1138 | 1137 | ||
1139 | if (build_expire(skb, x, hard) < 0) | 1138 | if (build_expire(skb, x, c->data.hard) < 0) |
1140 | BUG(); | 1139 | BUG(); |
1141 | 1140 | ||
1142 | NETLINK_CB(skb).dst_groups = XFRMGRP_EXPIRE; | 1141 | NETLINK_CB(skb).dst_groups = XFRMGRP_EXPIRE; |
@@ -1162,7 +1161,7 @@ static int xfrm_notify_sa_flush(struct km_event *c) | |||
1162 | nlh->nlmsg_flags = 0; | 1161 | nlh->nlmsg_flags = 0; |
1163 | 1162 | ||
1164 | p = NLMSG_DATA(nlh); | 1163 | p = NLMSG_DATA(nlh); |
1165 | p->proto = c->data; | 1164 | p->proto = c->data.proto; |
1166 | 1165 | ||
1167 | nlh->nlmsg_len = skb->tail - b; | 1166 | nlh->nlmsg_len = skb->tail - b; |
1168 | 1167 | ||
@@ -1404,7 +1403,7 @@ static int xfrm_exp_policy_notify(struct xfrm_policy *xp, int dir, struct km_eve | |||
1404 | if (skb == NULL) | 1403 | if (skb == NULL) |
1405 | return -ENOMEM; | 1404 | return -ENOMEM; |
1406 | 1405 | ||
1407 | if (build_polexpire(skb, xp, dir, c->data) < 0) | 1406 | if (build_polexpire(skb, xp, dir, c->data.hard) < 0) |
1408 | BUG(); | 1407 | BUG(); |
1409 | 1408 | ||
1410 | NETLINK_CB(skb).dst_groups = XFRMGRP_EXPIRE; | 1409 | NETLINK_CB(skb).dst_groups = XFRMGRP_EXPIRE; |