imap_proxy_get_state,
client_common_send_raw_data,
imap_client_input_next_cmd,
+ client_common_default_free,
};
static const struct login_binary imap_login_binary = {
NULL,
client_common_send_raw_data,
NULL,
+ client_common_default_free,
};
static const struct login_binary imap_urlauth_login_binary = {
i_assert(client->destroyed);
i_assert(client->login_proxy == NULL);
+ if (client->v.free != NULL)
+ client->v.free(client);
+
if (client->ssl_proxy != NULL)
ssl_proxy_free(&client->ssl_proxy);
if (client->input != NULL)
return FALSE;
}
+void client_common_default_free(struct client *client ATTR_UNUSED)
+{
+}
+
void client_destroy_oldest(void)
{
struct client *client;
void (*send_raw_data)(struct client *client,
const void *data, size_t size);
bool (*input_next_cmd)(struct client *client);
+ void (*free)(struct client *client);
};
struct client {
void client_send_raw(struct client *client, const char *data);
void client_common_send_raw_data(struct client *client,
const void *data, size_t size);
+void client_common_default_free(struct client *client);
void client_set_auth_waiting(struct client *client);
void client_auth_send_challenge(struct client *client, const char *data);
pop3_proxy_get_state,
client_common_send_raw_data,
pop3_client_input_next_cmd,
+ client_common_default_free,
};
static const struct login_binary pop3_login_binary = {