Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 821
b: refs/heads/master
c: 679a873
h: refs/heads/master
i:
  819: 710b23d
v: v3
  • Loading branch information
Herbert Xu authored and David S. Miller committed May 3, 2005
1 parent 3f4581c commit 76b4c05
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 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: 31da185d8162ae0f30a13ed945f1f4d28d158133
refs/heads/master: 679a87382433cf12a28f07a7d5c240f30f0daa08
7 changes: 4 additions & 3 deletions trunk/net/ipv6/raw.c
Original file line number Diff line number Diff line change
Expand Up @@ -455,11 +455,11 @@ static int rawv6_recvmsg(struct kiocb *iocb, struct sock *sk,
static int rawv6_push_pending_frames(struct sock *sk, struct flowi *fl,
struct raw6_sock *rp)
{
struct inet_sock *inet = inet_sk(sk);
struct sk_buff *skb;
int err = 0;
int offset;
int len;
int total_len;
u32 tmp_csum;
u16 csum;

Expand All @@ -470,7 +470,8 @@ static int rawv6_push_pending_frames(struct sock *sk, struct flowi *fl,
goto out;

offset = rp->offset;
if (offset >= inet->cork.length - 1) {
total_len = inet_sk(sk)->cork.length - (skb->nh.raw - skb->data);
if (offset >= total_len - 1) {
err = -EINVAL;
ip6_flush_pending_frames(sk);
goto out;
Expand Down Expand Up @@ -514,7 +515,7 @@ static int rawv6_push_pending_frames(struct sock *sk, struct flowi *fl,

tmp_csum = csum_ipv6_magic(&fl->fl6_src,
&fl->fl6_dst,
inet->cork.length, fl->proto, tmp_csum);
total_len, fl->proto, tmp_csum);

if (tmp_csum == 0)
tmp_csum = -1;
Expand Down

0 comments on commit 76b4c05

Please sign in to comment.