[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: commit: ldap/libraries/libldap result.c



Howard Chu writes:
>Pierangelo Masarati wrote:
>> hyc@OpenLDAP.org wrote:
>>> Update of /repo/OpenLDAP/pkg/ldap/libraries/libldap
>>>
>>> Modified Files:
>>> 	result.c  1.149 -> 1.150
>>>
>>> Log Message:
>>> Fairly sure this is what the TIMEOUT option should always have been for
>>
>> Not strictly related, but does it make sense to have a malloc for a
>> struct timeval in global/per handler data?  Wouldn't it be any better to
>> use tv_sec = -1 to indicate no timeout?  We should be able to change
>> that, since the struct is opaque...
>
> Hm. What about changing the get_option call? Currently it mallocs a timeval
> and returns a pointer to that. It ought to just copy the contents of the
> timeval. They've only been documented in HEAD; can we change it or would that
> break something?

Do you mean ldap_get_option()?  It generally returns malloced data,
IIRC.  "undocumented" just means the code has been the documentation, so
I presume a change will break any old code which uses it.

-- 
Regards,
Hallvard