When passing received pbuf allocated with PBUF_TYPE_FLAG_DATA_VOLATILE (e.g. PBUF_REF) to tcpip_input(), the pbuf is immediately queued without checking the volatile flag.
The comment on the volatile flag says:
/** Indicates the data stored in this pbuf can change. If this pbuf needs
* to be queued, it must be copied/duplicated. */
The behavior seems contradictory to the flag's description. Am I reading it right? Should the comment be read only in the context of the lwip core, or maybe it only applies to transmitted packets?
Thanks.