openldap: Remove custom string/bool/int config functions.

Roughly the equivalent of e4ab153f9, as this part of the code was copied
from the apache plugin.
openldap: remove unused element from ldap_s struct
openldap: properly free allocated resources on transient errors