This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Incorrect addrlen when calling connect


On Wed, Jun 25, 2008 at 2:19 AM, Ulrich Drepper <drepper@redhat.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> David Bartley wrote:
>> This is an issue on Solaris, which I'm aware is not a supported
>> platform. This patch would improve portability without any drawbacks
>> that I can see.
>
> The reason it's not done is that it unnecessarily increases code size
> and makes the program slower.  So, it's not no-impact.

The call to connect would far outweigh any cost imposed by a simple
comparison and assignment that this patch would add. If you are really
worried about code size, you should cut down some of the error
strings; I reckon that replacing all instances of the string 'garbage'
with 'junk' would save more memory than this patch would take.

If this code is so troublesome, why is this same code used elsewhere
in res_send.c?

-- David


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]