gtp: fix the order of error cases in gtp_encap_enable

The ordering of the error case exit was wrong and would
attempt to release the wrong socket.

Signed-off-by: Andreas Schultz <aschultz@tpip.net>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
Andreas Schultz 2015-11-16 16:06:48 +01:00 committed by Pablo Neira Ayuso
parent b40f105841
commit 976dcfc9f1
1 changed files with 2 additions and 2 deletions

4
gtp.c
View File

@ -933,10 +933,10 @@ static int gtp_encap_enable(struct net_device *dev, struct gtp_instance *gti,
sk->sk_user_data = gti;
return 0;
err1:
sockfd_put(sock0);
err2:
sockfd_put(sock1u);
err1:
sockfd_put(sock0);
return err;
}