[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1318906907.2571.39.camel@edumazet-laptop>
Date: Tue, 18 Oct 2011 05:01:47 +0200
From: Eric Dumazet <eric.dumazet@...il.com>
To: David Miller <davem@...emloft.net>
Cc: netdev <netdev@...r.kernel.org>, Dmitry Kozlov <xeb@...l.ru>
Subject: [PATCH] pptp: fix skb leak in pptp_xmit()
In case we cant transmit skb, we must free it
Signed-off-by: Eric Dumazet <eric.dumazet@...il.com>
CC: Dmitry Kozlov <xeb@...l.ru>
---
drivers/net/pptp.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/pptp.c b/drivers/net/pptp.c
index eae542a..9c0403d 100644
--- a/drivers/net/pptp.c
+++ b/drivers/net/pptp.c
@@ -285,8 +285,10 @@ static int pptp_xmit(struct ppp_channel *chan, struct sk_buff *skb)
ip_send_check(iph);
ip_local_out(skb);
+ return 1;
tx_error:
+ kfree_skb(skb);
return 1;
}
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists