Hi,
What am I missing as the ldap_result function does not seem to care at all about the timeout value given to it? I would need polling behavior and I have tried to give it a timeval of zero, 2 seconds and other small values but often it does not return until over a minute has passed. I have also tried to call ldap_set_option( m_ldap, LDAP_OPT_TIMEOUT, &timeout ) first where the timeout has been zero, 2 seconds etc. but it does not have any effect either. Sometimes ldap_result takes very long also after a call to ldap_simple_bind but usually this happens after a call to ldap_search_ext.
Also abandoning a lengthy ldap_result operation is not an option as ldap_result will throw an access violation if it is given an abandoned message identifier. And without access to the internals of the ldap library I cannot synchronize the abandoning so that it would take place only after ldap_result has proceeded so far that it is ok for it to abandon the identifier.
My code used OpenLDAP version 1.168.2.16 where this issue occurred, then I upgraded it to version 2.4.42 to see if it behaves differently (with #define LDAP_DEPRECATED 1 for now for simplicity) but the same issue seems to be there.
I am developing and testing with Windows 8.1 but the same issue is also at least in Mac OS.
Any help will be greatly appreciated. Thanks!
- Ilja
openldap-technical@openldap.org