Altera_Forum
Honored Contributor
20 years agopossible missmatch between rcvevent and pbuf
Hi everybody,
I am using lwip with uc/os ii and the socket api to establish an udp connection. During program execution it might happen, that the pbuf fills up. Trying to empty it, I have recognized that recvfrom() blocks even though I am using the flag MSG_DONTWAIT. Using select() to see if data is pending or lwip_ioctl() to check how many bytes are available will not work. My only explanation for this behavior would be that even though no more data can be stored in pbuf, rcvevent and recv_avail are incremented, and therefore recvfrom(), select and lwip_ioctl() are awaiting pbuf to hold mor data than there is available. Any ideas for a work around? --wolf