Skip to content

Commit

Permalink
ppp: fix pptp double release_sock in pptp_bind()
Browse files Browse the repository at this point in the history
Signed-off-by: Djalal Harouni <tixxdz@opendz.org>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Djalal Harouni authored and David S. Miller committed Dec 7, 2011
1 parent 43af940 commit a454dac
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/net/ppp/pptp.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit a454dac

Please sign in to comment.