]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-ldap: Drop ldap_client_init()
authorMarco Bettini <marco.bettini@open-xchange.com>
Mon, 9 Dec 2024 10:03:02 +0000 (10:03 +0000)
committerAki Tuomi <aki.tuomi@open-xchange.com>
Fri, 17 Jan 2025 08:40:01 +0000 (10:40 +0200)
src/lib-ldap/ldap-client.c
src/lib-ldap/ldap-client.h

index 4f4460ed984ce4050777bf7fac47b7ae2aacf4ce..ee0b25156116c60dc54f67c22551f19ee1e97588 100644 (file)
@@ -17,25 +17,6 @@ struct ldap_client {
 
 static struct ldap_connection_pool *ldap_conn_pool = NULL;
 
-int ldap_client_init(const struct ldap_client_settings *set,
-                    struct ldap_client **client_r, const char **error_r)
-{
-       struct ldap_client *client;
-
-       if (ldap_conn_pool == NULL)
-               ldap_conn_pool = ldap_connection_pool_init(LDAP_CONN_POOL_MAX_CONNECTIONS);
-
-       client = i_new(struct ldap_client, 1);
-       client->event = event_create(set->event_parent);
-       if (ldap_connection_pool_get(ldap_conn_pool, client, set,
-                                    &client->list, error_r) < 0) {
-               i_free(client);
-               return -1;
-       }
-       *client_r = client;
-       return 0;
-}
-
 int ldap_client_init_auto(struct event *event, struct ldap_client **client_r,
                          const char **error_r)
 {
index 11f6d2bb21a76d1a0e210a0ff2fd5fd131aa44ab..3421c7197c35e159d18b35de6d202460d499f3d3 100644 (file)
@@ -39,8 +39,6 @@ struct ldap_compare_input {
 
 /* Initialize LDAP. Returns 0 on success, or -1 and error_r if initialization
    failed with the given settings. */
-int ldap_client_init(const struct ldap_client_settings *set,
-                    struct ldap_client **client_r, const char **error_r);
 int ldap_client_init_auto(struct event *event, struct ldap_client **client_r,
                          const char **error_r);
 void ldap_client_deinit(struct ldap_client **client);