Mercurial > dovecot > core-2.2
view src/lib-lda/smtp-client.h @ 23017:c1d36f2575c7 default tip
lib-imap: Fix "Don't accept strings with NULs" cherry-pick
author | Timo Sirainen <timo.sirainen@open-xchange.com> |
---|---|
date | Thu, 29 Aug 2019 09:55:25 +0300 |
parents | bf2dbc8ec74b |
children |
line wrap: on
line source
#ifndef SMTP_CLIENT_H #define SMTP_CLIENT_H struct smtp_client * ATTR_NULL(3) smtp_client_init(const struct lda_settings *set, const char *return_path); /* Add a new recipient */ void smtp_client_add_rcpt(struct smtp_client *client, const char *address); /* Get an output stream where the message can be written to. The recipients must already be added before calling this. */ struct ostream *smtp_client_send(struct smtp_client *client); void smtp_client_abort(struct smtp_client **client); /* Returns 1 on success, 0 on permanent failure (e.g. invalid destination), -1 on temporary failure. */ int smtp_client_deinit(struct smtp_client *client, const char **error_r); /* Same as smtp_client_deinit(), but timeout after given number of seconds. */ int smtp_client_deinit_timeout(struct smtp_client *client, unsigned int timeout_secs, const char **error_r); /* FIXME: obsolete API, remove in v2.3: */ struct smtp_client * ATTR_NULL(3) smtp_client_open(const struct lda_settings *set, const char *destination, const char *return_path, struct ostream **output_r); /* Returns sysexits-compatible return value */ int smtp_client_close(struct smtp_client *client); #endif