summaryrefslogtreecommitdiffstats
path: root/net/batman-adv/soft-interface.c
diff options
context:
space:
mode:
authorSven Eckelmann <sven@narfation.org>2016-06-27 08:15:42 +0200
committerSimon Wunderlich <sw@simonwunderlich.de>2016-08-09 07:54:33 +0200
commitf19dc7770f5d55274ef9821392199daca03469a9 (patch)
tree3057a28549d424cf4f455634547bc2db48ad7ae4 /net/batman-adv/soft-interface.c
parentbatman-adv: use kmem_cache for translation table (diff)
downloadlinux-f19dc7770f5d55274ef9821392199daca03469a9.tar.xz
linux-f19dc7770f5d55274ef9821392199daca03469a9.zip
batman-adv: Remove orig_node reference handling from send_skb_unicast
The function batadv_send_skb_unicast is not acquiring a reference for an orig_node nor removing it from any datastructure. It still reduces the reference counter for an object which is still in the hands of the caller. This is confusing and can lead in the future to problems in the reference handling of the caller function. Signed-off-by: Sven Eckelmann <sven@narfation.org> Acked-by: Linus Lüssing <linus.luessing@c0d3.blue> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
Diffstat (limited to '')
-rw-r--r--net/batman-adv/soft-interface.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c
index 216ac03ab432..e508bf5957b3 100644
--- a/net/batman-adv/soft-interface.c
+++ b/net/batman-adv/soft-interface.c
@@ -57,6 +57,7 @@
#include "hard-interface.h"
#include "multicast.h"
#include "network-coding.h"
+#include "originator.h"
#include "packet.h"
#include "send.h"
#include "sysfs.h"
@@ -377,6 +378,8 @@ dropped:
dropped_freed:
batadv_inc_counter(bat_priv, BATADV_CNT_TX_DROPPED);
end:
+ if (mcast_single_orig)
+ batadv_orig_node_put(mcast_single_orig);
if (primary_if)
batadv_hardif_put(primary_if);
return NETDEV_TX_OK;