netlink: remove subscriptions check on notifier
authorJohannes Berg <johannes@sipsolutions.net>
Mon, 16 Nov 2009 12:05:34 +0000 (12:05 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 17 Nov 2009 12:08:49 +0000 (04:08 -0800)
The netlink URELEASE notifier doesn't notify for
sockets that have been used to receive multicast
but it should be called for such sockets as well
since they might _also_ be used for sending and
not solely for receiving multicast. We will need
that for nl80211 (generic netlink sockets) in the
future.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Cc: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/netlink/af_netlink.c

index f30d596dbc584e801fa0194cab2f3b9494e2e3bc..eff5b0ddc5ca7757d659a2f7bd892f902ff5790e 100644 (file)
@@ -498,7 +498,7 @@ static int netlink_release(struct socket *sock)
 
        skb_queue_purge(&sk->sk_write_queue);
 
-       if (nlk->pid && !nlk->subscriptions) {
+       if (nlk->pid) {
                struct netlink_notify n = {
                                                .net = sock_net(sk),
                                                .protocol = sk->sk_protocol,