Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75619
b: refs/heads/master
c: d4782c3
h: refs/heads/master
i:
  75617: 2bd75f6
  75615: 0c4f7c1
v: v3
  • Loading branch information
Patrick McHardy authored and David S. Miller committed Jan 21, 2008
1 parent 67d4efd commit 95c714a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 421c991483a6e52091cd2120c007cbc220d669ae
refs/heads/master: d4782c323d10d3698b71b6a6b3c7bdad33824658
16 changes: 9 additions & 7 deletions trunk/net/key/af_key.c
Original file line number Diff line number Diff line change
Expand Up @@ -3593,27 +3593,29 @@ static int pfkey_send_migrate(struct xfrm_selector *sel, u8 dir, u8 type,
/* old ipsecrequest */
int mode = pfkey_mode_from_xfrm(mp->mode);
if (mode < 0)
return -EINVAL;
goto err;
if (set_ipsecrequest(skb, mp->proto, mode,
(mp->reqid ? IPSEC_LEVEL_UNIQUE : IPSEC_LEVEL_REQUIRE),
mp->reqid, mp->old_family,
&mp->old_saddr, &mp->old_daddr) < 0) {
return -EINVAL;
}
&mp->old_saddr, &mp->old_daddr) < 0)
goto err;

/* new ipsecrequest */
if (set_ipsecrequest(skb, mp->proto, mode,
(mp->reqid ? IPSEC_LEVEL_UNIQUE : IPSEC_LEVEL_REQUIRE),
mp->reqid, mp->new_family,
&mp->new_saddr, &mp->new_daddr) < 0) {
return -EINVAL;
}
&mp->new_saddr, &mp->new_daddr) < 0)
goto err;
}

/* broadcast migrate message to sockets */
pfkey_broadcast(skb, GFP_ATOMIC, BROADCAST_ALL, NULL);

return 0;

err:
kfree_skb(skb);
return -EINVAL;
}
#else
static int pfkey_send_migrate(struct xfrm_selector *sel, u8 dir, u8 type,
Expand Down

0 comments on commit 95c714a

Please sign in to comment.