61 #define STR(x) vstring_str(x)
78 rcpt,
"none", dsn) != 0) {
87 const char *myname =
"cleanup_bounce";
91 const char *dsn_status;
105 const char *encoding;
106 const char *dsn_envid;
120 dsn_status = detail->
dsn;
121 dsn_text = detail->
text;
147 if ((rec_type =
rec_get(state->
dst, buf, 0)) <= 0
168 if (
alldig(start) && (junk = atoi(start)) > 0
182 dsn_orcpt ? dsn_orcpt :
"", dsn_notify,
183 orig_rcpt ? orig_rcpt : rcpt, rcpt);
184 (void)
DSN_SIMPLE(&dsn, dsn_status, dsn_text);
185 cleanup_bounce_append(state, &recipient, &dsn);
189 if (orig_rcpt != 0) {
193 if (dsn_orcpt != 0) {
211 (void)
DSN_SIMPLE(&dsn, dsn_status, dsn_text);
212 cleanup_bounce_append(state, &recipient, &dsn);
241 if (bounce_err != 0) {
256 return (state->
errs);
const CLEANUP_STAT_DETAIL * cleanup_stat_detail(unsigned status)
DSN_SPLIT * dsn_split(DSN_SPLIT *dp, const char *def_dsn, const char *text)
char * mystrdup(const char *str)
#define MAIL_ATTR_ENCODING
#define DSN_SIMPLE(dsn, _status, _reason)
#define CLEANUP_STAT_SIZE
off_t vstream_ftell(VSTREAM *stream)
#define vstream_clearerr(vp)
#define CLEANUP_FLAG_DISCARD
#define DSN_STATUS(dsn_buf)
int alldig(const char *string)
#define RECIPIENT_ASSIGN(rcpt, offs, orcpt, notify, orig, addr)
const char * split_nameval(char *buf, char **name, char **value)
#define REC_TYPE_DSN_NOTIFY
#define BOUNCE_FLAG_CLEAN
int bounce_append(int flags, const char *id, MSG_STATS *stats, RECIPIENT *rcpt, const char *relay, DSN *dsn)
#define MAIL_ATTR_ENC_NONE
#define REC_TYPE_DSN_ORCPT
int bounce_flush(int flags, const char *queue, const char *id, const char *encoding, int smtputf8, const char *sender, const char *dsn_envid, int dsn_ret)
#define VSTREAM_PURGE_BOTH
void msg_warn(const char *fmt,...)
VSTRING * vstring_alloc(ssize_t len)
int rec_attr_map(const char *attr_name)
#define CLEANUP_MSG_STATS(stats, state)
NORETURN msg_fatal(const char *fmt,...)
off_t vstream_fseek(VSTREAM *stream, off_t offset, int whence)
int vstream_fflush(VSTREAM *stream)
#define CLEANUP_STAT_CONT
int bounce_flush_verp(int flags, const char *queue, const char *id, const char *encoding, int smtputf8, const char *sender, const char *dsn_envid, int dsn_ret, const char *verp_delims)
int cleanup_bounce(CLEANUP_STATE *state)
VSTRING * vstring_free(VSTRING *vp)
#define CLEANUP_STAT_WRITE
#define nvtable_find(table, key)
#define rec_get(fp, buf, limit)
int vstream_fpurge(VSTREAM *stream, int direction)
#define vstream_ferror(vp)