ax25: missplaced sock_put(sk)
authorBernard Pidoux F6BVP <f6bvp@free.fr>
Thu, 26 Aug 2010 11:40:00 +0000 (11:40 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Aug 2010 22:18:27 +0000 (15:18 -0700)
This patch moves a missplaced sock_put(sk) after
bh_unlock_sock(sk)
like in other parts of AX25 driver.

Signed-off-by: Bernard Pidoux <f6bvp@free.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ax25/ax25_ds_timer.c

index 2ce79df00680eee3d9d290fd1156ac1d2ab74557..c7d81436213d13e24e67edf2630930e5c4ed08c0 100644 (file)
@@ -112,8 +112,8 @@ void ax25_ds_heartbeat_expiry(ax25_cb *ax25)
                        if (sk) {
                                sock_hold(sk);
                                ax25_destroy_socket(ax25);
-                               sock_put(sk);
                                bh_unlock_sock(sk);
+                               sock_put(sk);
                        } else
                                ax25_destroy_socket(ax25);
                        return;