[Top][All Lists]

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

[lwip-devel] [task #7017] Implement DNS client

From: Frédéric Bernon
Subject: [lwip-devel] [task #7017] Implement DNS client
Date: Wed, 20 Jun 2007 08:56:13 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv: Gecko/20070515 Firefox/

Follow-up Comment #7, task #7017 (project lwip):

You're right about resolv, but "dns" seems more clear than "resolv".

Some remarks about the resolv.c code:

- MAX_NAME_LENGTH is 32. But a FQDN can be really longer. From memory, each
"label" of the FQDN can have 63 bytes, the number of labels of a FQDN can be
127, and the FQDN can be max 254. I will check the chapter in RFC to get
exact values, but it's sure it's more than 2.

- I don't see in the code where the dns_table cache is cleaned from old
entries. So, if a host already resolved change its IP address, we can't reach
it... Perhaps I miss simething.

- Only one DNS server ("primary") is defined. As I said in comment#2, a
secondary would be good.

- It would be good to check return values for pbuf_alloc, udp_new()..

- dns_table in resolv_init should be initialized with STATE_UNUSED (and not

- If your send in a short time (shorter than the "not found" timeout) more
than LWIP_RESOLV_ENTRIES, the older client of resolv is "lost" but not its
callback "found" will never be called (like in STATE_ERROR case).

- I'm not sure than compressed answers is working (I have to go deeply). Jim,
do you have check that?

- And of course, some typo and coding style to do...



Reply to this item at:


  Message posté via/par Savannah

reply via email to

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