From: Djalal Harouni Date: Tue, 6 Dec 2011 15:47:12 +0000 (+0000) Subject: ppp: fix pptp double release_sock in pptp_bind() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a454daceb78844a09c08b6e2d8badcb76a5d73b9;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git ppp: fix pptp double release_sock in pptp_bind() Signed-off-by: Djalal Harouni Acked-by: Eric Dumazet Signed-off-by: David S. Miller --- diff --git a/drivers/net/ppp/pptp.c b/drivers/net/ppp/pptp.c index 89f829f5f725..f8a6853b692e 100644 --- a/drivers/net/ppp/pptp.c +++ b/drivers/net/ppp/pptp.c @@ -423,10 +423,8 @@ static int pptp_bind(struct socket *sock, struct sockaddr *uservaddr, lock_sock(sk); opt->src_addr = sp->sa_addr.pptp; - if (add_chan(po)) { - release_sock(sk); + if (add_chan(po)) error = -EBUSY; - } release_sock(sk); return error;