Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 352109
b: refs/heads/master
c: fc4e98d
h: refs/heads/master
i:
  352107: c5ac31b
v: v3
  • Loading branch information
Alexander Aring authored and David S. Miller committed Feb 6, 2013
1 parent 9704a4f commit 0470468
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 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: a07fdceccf9d9f1b87f781e9a87662182e590d70
refs/heads/master: fc4e98dbbaa30ca2180df0b2b0d0608045ed3f19
13 changes: 4 additions & 9 deletions trunk/net/ieee802154/6lowpan.c
Original file line number Diff line number Diff line change
Expand Up @@ -377,17 +377,14 @@ static int lowpan_header_create(struct sk_buff *skb,
struct ipv6hdr *hdr;
const u8 *saddr = _saddr;
const u8 *daddr = _daddr;
u8 *head;
u8 head[100];
struct ieee802154_addr sa, da;

/* TODO:
* if this package isn't ipv6 one, where should it be routed?
*/
if (type != ETH_P_IPV6)
return 0;
/* TODO:
* if this package isn't ipv6 one, where should it be routed?
*/
head = kzalloc(100, GFP_KERNEL);
if (head == NULL)
return -ENOMEM;

hdr = ipv6_hdr(skb);
hc06_ptr = head + 2;
Expand Down Expand Up @@ -561,8 +558,6 @@ static int lowpan_header_create(struct sk_buff *skb,
skb_pull(skb, sizeof(struct ipv6hdr));
memcpy(skb_push(skb, hc06_ptr - head), head, hc06_ptr - head);

kfree(head);

lowpan_raw_dump_table(__func__, "raw skb data dump", skb->data,
skb->len);

Expand Down

0 comments on commit 0470468

Please sign in to comment.