>> From documentation, abuot tcp_listen_with_backlog function:
>> (...) Setting the connection to LISTEN is an irreversible process.
>
> It is irreversible in that you can't make it back into a "normal" pcb,
> but you can still close it, then do exactly what you're doing now (i.e.
> allocate, bind, listen, accept) when you want to make a new listening
> socket.

I put tcp_close(ListenPcb) in connection established callback and
                ListenPcb = tcp_new();
                tcp_bind(ListenPcb, IP_ADDR_ANY, 80);//todo: PORT HTTP
                ListenPcb = tcp_listen_with_backlog(ListenPcb, 1);      
                tcp_accept(ListenPcb, HTTP_connection_established);
in connection closing function.

Now the webside is loading much faster, but still sometimes there are
delays. I think delays appears the browser asks for more then 2
element at once.

_______________________________________________
lwip-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to