Skip to content

Commit

Permalink
[NET]: Fix kfree(skb)
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick McHardy <[email protected]>
Acked-by: Paul Moore <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
kaber authored and David S. Miller committed Feb 28, 2007
1 parent 4498121 commit b08d584
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion net/core/skbuff.c
Original file line number Diff line number Diff line change
Expand Up @@ -2037,7 +2037,7 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int features)
err:
while ((skb = segs)) {
segs = skb->next;
kfree(skb);
kfree_skb(skb);
}
return ERR_PTR(err);
}
Expand Down
2 changes: 1 addition & 1 deletion net/dccp/output.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ void dccp_write_xmit(struct sock *sk, int block)
err);
} else {
dccp_pr_debug("packet discarded\n");
kfree(skb);
kfree_skb(skb);
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion net/netlabel/netlabel_unlabeled.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ static int netlbl_unlabel_list(struct sk_buff *skb, struct genl_info *info)
return 0;

list_failure:
kfree(ans_skb);
kfree_skb(ans_skb);
return ret_val;
}

Expand Down
2 changes: 1 addition & 1 deletion net/xfrm/xfrm_user.c
Original file line number Diff line number Diff line change
Expand Up @@ -1401,7 +1401,7 @@ static int xfrm_get_ae(struct sk_buff *skb, struct nlmsghdr *nlh,

x = xfrm_state_lookup(&id->daddr, id->spi, id->proto, id->family);
if (x == NULL) {
kfree(r_skb);
kfree_skb(r_skb);
return -ESRCH;
}

Expand Down

0 comments on commit b08d584

Please sign in to comment.