[L2TP] Fix double skb free problem introduced by recent changes 

This patch is to be applied on top of Herbert's recent patch set:
"[PPP 3/3] L2TP: Fix skb handling in pppol2tp_xmit"

It fixes a double kfree_skb() issue introduced by that patch. Also
return 0 on error, allowing PPP to requeue the skb.

Signed-off-by: James Chapman <[EMAIL PROTECTED]>

Index: net-2.6.24/drivers/net/pppol2tp.c
===================================================================
--- net-2.6.24.orig/drivers/net/pppol2tp.c
+++ net-2.6.24/drivers/net/pppol2tp.c
@@ -1066,11 +1066,10 @@ static int pppol2tp_xmit(struct ppp_chan
                session->stats.tx_errors++;
        }
 
-       /* Free the original skb */
-abort:
-       kfree_skb(skb);
-
        return 1;
+
+abort:
+       return 0;
 }
 
 /*****************************************************************************
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to