Full_Name: Stef Walter Version: 2.4.35 OS: Fedora 18 URL: http://fedorapeople.org/~stefw/patches/openldap-02/0001-Make-ldap_init_fd-wo... Submission from: (NULL) (77.3.95.123)
The ldap_init_fd() function does not work with UDP sockets (ie: LDAP_PROTO_UDP passed in as the proto argument). Later uses of the LDAP connection returned fail unceremoniously.
This patch fixes the issue:
http://fedorapeople.org/~stefw/patches/openldap-02/0001-Make-ldap_init_fd-wo...
Some test code to exercise and demonstrate the problem. The code does not actually wait for a UDP response, but should exit with a zero return code when successful.
http://fedorapeople.org/~stefw/patches/openldap-02/frob-cldap-initfd.c
$ gcc -o frob-cldap-initfd -Wall -lldap -llber frob-cldap-initfd.c $ ./frob-cldap-initfd frob-cldap-initfd: ldap_search_ext: -1
The above result occurs before the patch is applied.