1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-31 09:21:19 +01:00

gnrc_sixlowpan: stop type-finding loop when type is found

Currently the loop just continues to run after a viable type is found.
In #10851 this lead to a crash of the tests, when the dependency of
`gnrc_sixlowpan` to `gnrc_ipv6` was removed.
This commit is contained in:
Martine Lenders 2019-01-25 12:03:18 +01:00
parent 03ed77b141
commit 879321d68a

View File

@ -73,6 +73,7 @@ void gnrc_sixlowpan_dispatch_recv(gnrc_pktsnip_t *pkt, void *context,
ptr = ptr->next) {
if ((ptr->next) && (ptr->next->type == GNRC_NETTYPE_NETIF)) {
type = ptr->type;
break;
}
}
#else /* MODULE_GNRC_IPV6 */