[Top][All Lists]

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

[lwip-devel] [task #6969] Review usage of conn->err in netconn layer

From: Frédéric Bernon
Subject: [lwip-devel] [task #6969] Review usage of conn->err in netconn layer
Date: Sat, 02 Jun 2007 10:51:28 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; fr; rv: Gecko/20070309 Firefox/

Follow-up Comment #1, task #6969 (project lwip):

For netconn_peer and netconn_addr, I propose to simply replace :

return (conn->err = ERR_OK);


return ERR_OK;

Because there is no reason to change conn->err when we just read a state

For the MAC problem (out of buffers could block sending more data), if I
resume some ideas in the mailing list, we can:

- not return an error in this case (finally, you also can lost packets on the
wire, TCP will retransmit datas - longer than necessary - so...)

- block inside the netif's linkoutput until a buffer is available (Jonathan
get a option in his port, and I add one in mine, this solution is not so

- filter the ERR_MEM error like a minor error (by adding a test just after a
udp_send/udp_sendto by example, and reset it to ERR_OK),

- we also can make a "filter) for "fatal errors" like this:

#define ERR_IS_FATAL(e) (e>ERR_BUF)

and change the several checkings in api_lib/api_msg by :

if (ERR_IS_FATAL(conn->err)) ...


Reply to this item at:


  Message posté via/par Savannah

reply via email to

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