Using the openldap c api