#include <gsasl.h>
#endif
+#ifdef USE_OPENLDAP
+#include <ldap.h>
+#endif
+
#ifdef HAVE_BROTLI
static size_t brotli_version(char *buf, size_t bufsz)
{
* zeros in the data.
*/
-#define VERSION_PARTS 16 /* number of substrings we can concatenate */
+#define VERSION_PARTS 17 /* number of substrings we can concatenate */
char *curl_version(void)
{
#endif
#ifdef USE_GSASL
char gsasl_buf[30];
+#endif
+#ifdef USE_OPENLDAP
+ char ldap_buf[30];
#endif
int i = 0;
int j;
gsasl_check_version(NULL));
src[i++] = gsasl_buf;
#endif
+#ifdef USE_OPENLDAP
+ {
+ LDAPAPIInfo api;
+ api.ldapai_info_version = LDAP_API_INFO_VERSION;
+
+ if(ldap_get_option(NULL, LDAP_OPT_API_INFO, &api) == LDAP_OPT_SUCCESS) {
+ unsigned int patch = api.ldapai_vendor_version % 100;
+ unsigned int major = api.ldapai_vendor_version / 10000;
+ unsigned int minor =
+ ((api.ldapai_vendor_version - major * 10000) - patch) / 100;
+ msnprintf(ldap_buf, sizeof(ldap_buf), "%s/%u.%u.%u",
+ api.ldapai_vendor_name, major, minor, patch);
+ src[i++] = ldap_buf;
+ }
+ }
+#endif
DEBUGASSERT(i <= VERSION_PARTS);