mirror of
https://github.com/apache/nuttx.git
synced 2026-09-29 18:45:22 +00:00
pkt_poll() records the outgoing IOB in pkt_conn->pendiob so that any synchronous TX tap or loopback executed during the driver callback can skip delivering the packet back to the sending socket. Previously, pendiob was never cleared upon TX completion and would linger across transmissions as a dangling pointer. Because the IOB pool is small and recycled quickly (LIFO), a subsequent incoming packet from the network frequently reused the same IOB buffer address, causing pkt_in() to drop legitimate RX packets as false self-echoes. Drop the pendiob reference immediately after callback(dev) returns in devif_poll_pkt_connections(), ensuring the pointer never outlives the transmission cycle. Also fixes a pre-existing nxstyle alignment issue in devif_poll.c IPv6 version-check block (unrelated nerr() call), since this file is now touched and CI enforces style on the whole file. Suggested-by: zhhyu7 Assisted-by: Gemini:gemini-3.8-flash-medium Signed-off-by: Daniel P. Carvalho <danieloak@gmail.com> |
||
|---|---|---|
| .. | ||
| CMakeLists.txt | ||
| devif.h | ||
| devif_callback.c | ||
| devif_filesend.c | ||
| devif_forward.c | ||
| devif_iobsend.c | ||
| devif_loopback.c | ||
| devif_poll.c | ||
| devif_send.c | ||
| ipv4_input.c | ||
| ipv6_input.c | ||
| Make.defs | ||