apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mladen Turk <mt...@apache.org>
Subject Re: svn commit: r442492 - /apr/apr/branches/1.2.x/network_io/unix/sockets.c
Date Wed, 20 Sep 2006 11:32:08 GMT
Joe Orton wrote:
> 
> If the API guarantee is "may allocate memory on failure" then the fix is 
> bad and should be reverted; the caller will have to do the 
> create/destroy dance anyway so it's needless overhead whether large or 
> small.
>

This was the case without my patch to unix/sockets.c
I was "will not allocate on Win32, will always allocate on unix".

> If the API guarantee is "will not allocate memory on failure" then 
> clearly this fix is necessary.  I think this option makes more sense.
> 

Of course we can have "will always allocate memory regardless of failure"
which was the case before the pacth (unix only), but like said it's resource
wasteful, and IMO we all agree on that.

Regards,
Mladen.


Mime
View raw message