]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
udp_diag: Fix socket skipping within chain
authorHerbert Xu <herbert@gondor.apana.org.au>
Fri, 23 Jan 2015 21:02:40 +0000 (08:02 +1100)
committerJiri Slaby <jslaby@suse.cz>
Tue, 10 Feb 2015 10:16:50 +0000 (11:16 +0100)
commitfd09a4de42024767c0fb9ea797e96454b0054130
treec9fba43c76b1427043ba331d0bc53527982762c0
parent8277cc54f4245d71a00acba3672616c1e3b4dc65
udp_diag: Fix socket skipping within chain

[ Upstream commit 86f3cddbc3037882414c7308973530167906b7e9 ]

While working on rhashtable walking I noticed that the UDP diag
dumping code is buggy.  In particular, the socket skipping within
a chain never happens, even though we record the number of sockets
that should be skipped.

As this code was supposedly copied from TCP, this patch does what
TCP does and resets num before we walk a chain.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Acked-by: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
net/ipv4/udp_diag.c