netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ipv6: Need to sock_put on zero csum error
@ 2014-05-05 20:11 Tom Herbert
  2014-05-05 20:23 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Tom Herbert @ 2014-05-05 20:11 UTC (permalink / raw)
  To: davem, netdev

Commit 4068579e1e098fa81d48db9ba4432ab664c58561 introduced
zero checksums being allowed for IPv6, but in the case that a
socket disallows a zero checksum we need to sock_put.

Signed-off-by: Tom Herbert <therbert@google.com>
---
 net/ipv6/udp.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index 4fcd9bc..fc2be63 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -884,6 +884,7 @@ int __udp6_lib_rcv(struct sk_buff *skb, struct udp_table *udptable,
 		int ret;
 
 		if (!uh->check && !sk->sk_no_check) {
+			sock_put(sk);
 			udp6_csum_zero_error(skb);
 			goto csum_error;
 		}
-- 
1.9.1.423.g4596e3a

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-05-05 20:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-05 20:11 [PATCH] ipv6: Need to sock_put on zero csum error Tom Herbert
2014-05-05 20:23 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).