version: free the openldap info correctly

... to avoid memory leaks.

Follow-up to: bf0feae776
Closes #7061
This commit is contained in:
Daniel Stenberg 2021-05-14 16:22:28 +02:00
parent 19291f7fb4
commit acf91ff75e
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
1 changed files with 2 additions and 0 deletions

View File

@ -267,6 +267,8 @@ char *curl_version(void)
msnprintf(ldap_buf, sizeof(ldap_buf), "%s/%u.%u.%u",
api.ldapai_vendor_name, major, minor, patch);
src[i++] = ldap_buf;
ldap_memfree(api.ldapai_vendor_name);
ber_memvfree((void **)api.ldapai_extensions);
}
}
#endif