Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 521251f2 authored by Antonio Quartulli's avatar Antonio Quartulli
Browse files

batman-adv: unset the TT_CLIENT_PENDING flag if the new local entry already exists



When trying to add a new tt_local_entry, if such entry already exists, we have
to ensure that the TT_CLIENT_PENDING flag is not set, otherwise the entry will
be deleted soon.

Reported-by: default avatarSimon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: default avatarAntonio Quartulli <ordex@autistici.org>
parent a77e8c61
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -206,6 +206,8 @@ void tt_local_add(struct net_device *soft_iface, const uint8_t *addr,

	if (tt_local_entry) {
		tt_local_entry->last_seen = jiffies;
		/* possibly unset the TT_CLIENT_PENDING flag */
		tt_local_entry->common.flags &= ~TT_CLIENT_PENDING;
		goto out;
	}