Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 86271
b: refs/heads/master
c: f449b3b
h: refs/heads/master
i:
  86269: 2622e9e
  86267: 47b4793
  86263: 5668976
  86255: 3750db1
  86239: b5c9c0c
  86207: cfedb2e
  86143: 2bffacb
  86015: ba75859
v: v3
  • Loading branch information
Pavel Emelyanov authored and David S. Miller committed Feb 20, 2008
1 parent 99120dd commit 5f505c2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 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: e2b58a67b91dec07dfb40ca2056c64011ce8489d
refs/heads/master: f449b3b54d2263d65a11429050765c325c9809f4
11 changes: 5 additions & 6 deletions trunk/net/netfilter/xt_u32.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ static bool u32_match_it(const struct xt_u32 *data,
u_int32_t pos;
u_int32_t val;
u_int32_t at;
int ret;

/*
* Small example: "0 >> 28 == 4 && 8 & 0xFF0000 >> 16 = 6, 17"
Expand All @@ -40,8 +39,8 @@ static bool u32_match_it(const struct xt_u32 *data,
if (skb->len < 4 || pos > skb->len - 4)
return false;

ret = skb_copy_bits(skb, pos, &n, sizeof(n));
BUG_ON(ret < 0);
if (skb_copy_bits(skb, pos, &n, sizeof(n)) < 0)
BUG();
val = ntohl(n);
nnums = ct->nnums;

Expand All @@ -67,9 +66,9 @@ static bool u32_match_it(const struct xt_u32 *data,
pos > skb->len - at - 4)
return false;

ret = skb_copy_bits(skb, at + pos, &n,
sizeof(n));
BUG_ON(ret < 0);
if (skb_copy_bits(skb, at + pos, &n,
sizeof(n)) < 0)
BUG();
val = ntohl(n);
break;
}
Expand Down

0 comments on commit 5f505c2

Please sign in to comment.