lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] Again confused about tcp_recved() and pbuf_free()


From: Giuseppe Modugno
Subject: [lwip-users] Again confused about tcp_recved() and pbuf_free()
Date: Sat, 23 Feb 2019 10:20:38 +0100

I know, this is a hot topic and many times this was explaied in the list and in doc/rawapi.txt, however now I'm in trouble understanding this.

tcp_recved() is related to the TCP window size of the receiver: "The purpose is to advertise a larger window when the data has been processed.". Isn't the TCP window size fixed to TCP_WND macro? Does it mean that the window size increases every time tcp_recved() is called from the application? I don't think, otherwise the window size increases continuously during a connection.

What are the situations when it should be better to not call tcp_recved() in recv() callback()? Here the application has the received data, can process and free the pbufs or can avoid freeing the pbufs to wait for additional data. In both cases I think the application should call tcp_recved().

reply via email to

[Prev in Thread] Current Thread [Next in Thread]