lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] Avoid connection close by lwIP server


From: Sylvain Rochet
Subject: Re: [lwip-users] Avoid connection close by lwIP server
Date: Mon, 16 Dec 2013 14:02:40 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

Hi Satz,


On Mon, Dec 16, 2013 at 12:18:57PM +0100, Satz Klauer wrote:
> 
> OK, to avoid misunderstandigs: I do NOT want to have a 
> HTTP-connection, I just used this example as starting point and to 
> test my underlying implementation.

Yep, that wasn't clear enough :-)


> Finally the whole thing shall become a plain TCP/IP connection where 
> client and lwIP-server communicate with each other over a longer time 
> and where connection is NOT closed after every response from server.
> 
> I know the http-example that comes with lwIP does this in a completely
> different way and I have to modify this example. The only thing I want
> to know and I did not understand until now: where in this example is
> the connection closed?

Given the lwIP raw API, connection is closed by/when:

a.  http_err() (which is the error callback previously set by tcp_err())
b.  tcp_close() (server initiating the shutdown)
c.  http_recv() which calls http_close_conn() if something went wrong
    or client closed the connection (pbuf is null)

Sylvain

Attachment: signature.asc
Description: Digital signature


reply via email to

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