From: Kazunori MIYAZAWA Date: Thu, 14 Feb 2008 22:51:38 +0000 (-0800) Subject: [AF_KEY]: Fix bug in spdadd X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a4d6b8af1e92daa872f55d06415b76c35f44d8bd;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [AF_KEY]: Fix bug in spdadd This patch fix a BUG when adding spds which have same selector. Signed-off-by: Kazunori MIYAZAWA Signed-off-by: David S. Miller --- diff --git a/net/key/af_key.c b/net/key/af_key.c index b3ac85e808ac..1c853927810a 100644 --- a/net/key/af_key.c +++ b/net/key/af_key.c @@ -2291,6 +2291,7 @@ static int pfkey_spdadd(struct sock *sk, struct sk_buff *skb, struct sadb_msg *h return 0; out: + xp->dead = 1; xfrm_policy_destroy(xp); return err; }