1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

Merge pull request #12405 from miri64/gnrc_netif/fix/deprecated-src-selection

gnrc_netif: avoid deprecated as source addresses, don't prefer them!
This commit is contained in:
Kaspar Schleiser 2019-10-09 21:25:38 +02:00 committed by GitHub
commit 80cbf1b523
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1042,7 +1042,7 @@ static ipv6_addr_t *_src_addr_selection(gnrc_netif_t *netif,
} }
} }
/* Rule 3: Avoid deprecated addresses. */ /* Rule 3: Avoid deprecated addresses. */
if (_get_state(netif, i) == GNRC_NETIF_IPV6_ADDRS_FLAGS_STATE_DEPRECATED) { if (_get_state(netif, i) != GNRC_NETIF_IPV6_ADDRS_FLAGS_STATE_DEPRECATED) {
DEBUG("winner for rule 3 found\n"); DEBUG("winner for rule 3 found\n");
winner_set[i] += RULE_3_PTS; winner_set[i] += RULE_3_PTS;
if (winner_set[i] > max_pts) { if (winner_set[i] > max_pts) {