batman-adv: Don't free unicast skb on failure
Commit Message
The soft-interface transmission function expects that the unicast skb is
still available when a send failed. Otherwise we would try to free the
skb twice and create many different and hard to debug memory access
failures due to access on not (anymore) allocated memory.
Reported-by: Andreas Langer <an.langer@gmx.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
---
unicast.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
@@ -264,6 +264,5 @@ int unicast_send_skb(struct sk_buff *skb, struct bat_priv *bat_priv)
unlock:
spin_unlock_irqrestore(&bat_priv->orig_hash_lock, flags);
dropped:
- kfree_skb(skb);
return 1;
}