public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Konstantin Khlebnikov <khlebnikov@yandex-team.ru>
To: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>
Cc: Eric Dumazet <edumazet@google.com>,
	Herbert Xu <herbert@gondor.apana.org.au>
Subject: [PATCH v2] netlink: reset skb->peeked when reuse orphan skb for next broadcast
Date: Fri, 10 Jul 2015 15:21:34 +0300	[thread overview]
Message-ID: <20150710122134.21653.46736.stgit@buzz> (raw)

This patch clears skb->peeked set by previous recipient of broadcast.

Signed-off-by: Konstantin Khlebnikov <khlebnikov@yandex-team.ru>
Fixes: add05ad4e9f5 ("unix/dgram: peek beyond 0-sized skbs")
---
 net/netlink/af_netlink.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c
index 921e0d8dfe3a..f4427f4bf223 100644
--- a/net/netlink/af_netlink.c
+++ b/net/netlink/af_netlink.c
@@ -1967,6 +1967,7 @@ static void do_one_broadcast(struct sock *sk,
 			 * delivered to a previous socket.
 			 */
 			skb_orphan(p->skb2);
+			p->skb2->peeked = 0;
 		}
 	}
 	if (p->skb2 == NULL) {

             reply	other threads:[~2015-07-10 12:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-10 12:21 Konstantin Khlebnikov [this message]
2015-07-13  8:05 ` [PATCH v2] netlink: reset skb->peeked when reuse orphan skb for next broadcast Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150710122134.21653.46736.stgit@buzz \
    --to=khlebnikov@yandex-team.ru \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox