Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 15533
b: refs/heads/master
c: 65a4544
h: refs/heads/master
i:
  15531: 9d3c593
v: v3
  • Loading branch information
Stephen Hemminger authored and David S. Miller committed Jan 3, 2006
1 parent 90955d8 commit 8750d07
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3305b80c214c642b89cd5c21af83bc91ec13f8bd
refs/heads/master: 65a45441d7e91ef6107fadbc55f775db4ba23874
6 changes: 2 additions & 4 deletions trunk/net/ipv4/udp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1081,7 +1081,7 @@ static int udp_v4_mcast_deliver(struct sk_buff *skb, struct udphdr *uh,
* Otherwise, csum completion requires chacksumming packet body,
* including udp header and folding it to skb->csum.
*/
static int udp_checksum_init(struct sk_buff *skb, struct udphdr *uh,
static void udp_checksum_init(struct sk_buff *skb, struct udphdr *uh,
unsigned short ulen, u32 saddr, u32 daddr)
{
if (uh->check == 0) {
Expand All @@ -1095,7 +1095,6 @@ static int udp_checksum_init(struct sk_buff *skb, struct udphdr *uh,
/* Probably, we should checksum udp header (it should be in cache
* in any case) and data in tiny packets (< rx copybreak).
*/
return 0;
}

/*
Expand Down Expand Up @@ -1128,8 +1127,7 @@ int udp_rcv(struct sk_buff *skb)
if (pskb_trim_rcsum(skb, ulen))
goto short_packet;

if (udp_checksum_init(skb, uh, ulen, saddr, daddr) < 0)
goto csum_error;
udp_checksum_init(skb, uh, ulen, saddr, daddr);

if(rt->rt_flags & (RTCF_BROADCAST|RTCF_MULTICAST))
return udp_v4_mcast_deliver(skb, uh, saddr, daddr);
Expand Down

0 comments on commit 8750d07

Please sign in to comment.