[PATCH] Fix multiple DNS queries when negative results returned
Bernhard Fischer
rep.dot.nop at gmail.com
Fri Jun 27 14:15:14 UTC 2008
On Fri, Jun 27, 2008 at 03:56:53PM +0200, Ricard Wanderlof wrote:
>
> On Fri, 27 Jun 2008, Bernhard Fischer wrote:
>
>>> Index: libc/inet/resolv.c
>>> ===================================================================
>>> --- libc/inet/resolv.c (revision 22530)
>>> +++ libc/inet/resolv.c (working copy)
>>> @@ -757,6 +757,7 @@
>>> #ifdef __UCLIBC_HAS_IPV4__
>>> struct sockaddr_in sa;
>>> #endif
>>> + bool negative_results[MAX_SEARCH + 1] = { 0 };
>>
>> unsigned no_results;
>> if (got negative result)
>> no_results |= (1 << variant)
>>
>> Which one is smaller? size(1), please.
>
> They are the same.
>
> With my configuration, size lib/libuClibc-0.9.29.so returns:
>
> text data bss dec hex filename
> 274873 5016 14376 294265 47d79 lib/libuClibc-0.9.29.so
>
> no matter whether I apply the patch as submitted, or use a bitmapped
> version. (Removing the off-the-end-of-the-array tests in the array
> version yields 20 bytes less; these tests aren't needed in the bitmapped
> version of course).
good, Thanks. Let's wait a little bit to hear if somebody objects to the
tweak in general.
cheers,
Bernhard
More information about the uClibc
mailing list