mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-25 18:14:53 +00:00
pbuf: Init pbuf if_idx to NETIF_NO_INDEX in pbuf_alloced_custom
Otherwise the p->pbuf.if_idx is uninitialized. Signed-off-by: Axel Lin <axel.lin@ingics.com>
This commit is contained in:
parent
ba1cf2fa44
commit
3aca7885a7
@ -430,6 +430,7 @@ pbuf_alloced_custom(pbuf_layer l, u16_t length, pbuf_type type, struct pbuf_cust
|
||||
p->pbuf.len = p->pbuf.tot_len = length;
|
||||
p->pbuf.type_internal = (u8_t)type;
|
||||
p->pbuf.ref = 1;
|
||||
p->pbuf.if_idx = NETIF_NO_INDEX;
|
||||
return &p->pbuf;
|
||||
}
|
||||
#endif /* LWIP_SUPPORT_CUSTOM_PBUF */
|
||||
|
Loading…
Reference in New Issue
Block a user