diff options
Diffstat (limited to 'net/llc/af_llc.c')
-rw-r--r-- | net/llc/af_llc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/net/llc/af_llc.c b/net/llc/af_llc.c index f49f3dd6fbd3..e35d907fba2c 100644 --- a/net/llc/af_llc.c +++ b/net/llc/af_llc.c | |||
@@ -197,10 +197,8 @@ static int llc_ui_release(struct socket *sock) | |||
197 | llc->laddr.lsap, llc->daddr.lsap); | 197 | llc->laddr.lsap, llc->daddr.lsap); |
198 | if (!llc_send_disc(sk)) | 198 | if (!llc_send_disc(sk)) |
199 | llc_ui_wait_for_disc(sk, sk->sk_rcvtimeo); | 199 | llc_ui_wait_for_disc(sk, sk->sk_rcvtimeo); |
200 | if (!sock_flag(sk, SOCK_ZAPPED)) { | 200 | if (!sock_flag(sk, SOCK_ZAPPED)) |
201 | llc_sap_put(llc->sap); | ||
202 | llc_sap_remove_socket(llc->sap, sk); | 201 | llc_sap_remove_socket(llc->sap, sk); |
203 | } | ||
204 | release_sock(sk); | 202 | release_sock(sk); |
205 | if (llc->dev) | 203 | if (llc->dev) |
206 | dev_put(llc->dev); | 204 | dev_put(llc->dev); |
@@ -352,7 +350,6 @@ static int llc_ui_bind(struct socket *sock, struct sockaddr *uaddr, int addrlen) | |||
352 | rc = -EBUSY; /* some other network layer is using the sap */ | 350 | rc = -EBUSY; /* some other network layer is using the sap */ |
353 | if (!sap) | 351 | if (!sap) |
354 | goto out; | 352 | goto out; |
355 | llc_sap_hold(sap); | ||
356 | } else { | 353 | } else { |
357 | struct llc_addr laddr, daddr; | 354 | struct llc_addr laddr, daddr; |
358 | struct sock *ask; | 355 | struct sock *ask; |