[Date Prev][Date Next]
Re: ldap_search_ext() blocks while establishing TCP connection?
Manish Godara writes:
> I'm looking into ldap client library code to see if
> any of the calls can block. I'm just wondering if the
> first call to ldap_search_ext() [after ldap_init()]
> can block for a short while to establish the TCP
It can. "Asynchronous" LDAP API functions can also block if the
socket buffer gets full: If the request is very large or if you
have sent a lot of calls that haven't been 'drained' yet.
That an function is "asynchronous" only means that it will not
wait for the server's response, so you must fetch that with a
separate function call.
OTOH, ldap_result() takes a timeout parameter which says for how
long the function may block.
> - what is the purpose of async parameter in
It is not (yet) used.