mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-28 09:19:53 +00:00
lowpan6: Fix incorrect array bounds check (found by Coverity)
This commit is contained in:
parent
9885d5d9f5
commit
cc4f94f415
@ -564,7 +564,7 @@ lowpan6_frag(struct netif *netif, struct pbuf *p, const struct ieee_802154_addr
|
|||||||
err_t
|
err_t
|
||||||
lowpan6_set_context(u8_t idx, const ip6_addr_t * context)
|
lowpan6_set_context(u8_t idx, const ip6_addr_t * context)
|
||||||
{
|
{
|
||||||
if (idx > LWIP_6LOWPAN_NUM_CONTEXTS) {
|
if (idx >= LWIP_6LOWPAN_NUM_CONTEXTS) {
|
||||||
return ERR_ARG;
|
return ERR_ARG;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user