diff options
author | Wei Yongjun <yjwei@cn.fujitsu.com> | 2009-02-24 19:16:08 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-02-27 02:07:30 -0500 |
commit | 1d2f8c950745f47f2937742eb886cffee439b754 (patch) | |
tree | 838292120aa46c3f3e46540f042354c034683739 /drivers/net/ppp_generic.c | |
parent | 875b48297b8ab2f402680821da47d23bd6bddc55 (diff) |
ppp: remove some pointless conditionals before kfree_skb()
Remove some pointless conditionals before kfree_skb().
Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ppp_generic.c')
-rw-r--r-- | drivers/net/ppp_generic.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c index ea8cdf8e4be8..42d455578453 100644 --- a/drivers/net/ppp_generic.c +++ b/drivers/net/ppp_generic.c | |||
@@ -1245,8 +1245,7 @@ ppp_send_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1245 | return; | 1245 | return; |
1246 | 1246 | ||
1247 | drop: | 1247 | drop: |
1248 | if (skb) | 1248 | kfree_skb(skb); |
1249 | kfree_skb(skb); | ||
1250 | ++ppp->dev->stats.tx_errors; | 1249 | ++ppp->dev->stats.tx_errors; |
1251 | } | 1250 | } |
1252 | 1251 | ||
@@ -2658,8 +2657,7 @@ static void ppp_destroy_interface(struct ppp *ppp) | |||
2658 | ppp->active_filter = NULL; | 2657 | ppp->active_filter = NULL; |
2659 | #endif /* CONFIG_PPP_FILTER */ | 2658 | #endif /* CONFIG_PPP_FILTER */ |
2660 | 2659 | ||
2661 | if (ppp->xmit_pending) | 2660 | kfree_skb(ppp->xmit_pending); |
2662 | kfree_skb(ppp->xmit_pending); | ||
2663 | 2661 | ||
2664 | free_netdev(ppp->dev); | 2662 | free_netdev(ppp->dev); |
2665 | } | 2663 | } |