diff options
author | Gilles Chehade <gilles@cvs.openbsd.org> | 2011-04-14 22:36:10 +0000 |
---|---|---|
committer | Gilles Chehade <gilles@cvs.openbsd.org> | 2011-04-14 22:36:10 +0000 |
commit | 8aa9805c6c6a07e2e443192c06997db291ce8f9f (patch) | |
tree | 022eb9addce61e7a4d44d85c893f3070da1123e5 /usr.sbin/smtpd/queue.c | |
parent | aa8d852e3859a12cf274f2a0baf898ec4c4e2138 (diff) |
- implement fsqueue_message_create() and fsqueue_message_commit()
- change a few prototypes to allow bounce messages to use the
queue_backend API until it gets merged in
- kill functions of the queue API that have been deprecated
Diffstat (limited to 'usr.sbin/smtpd/queue.c')
-rw-r--r-- | usr.sbin/smtpd/queue.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/smtpd/queue.c b/usr.sbin/smtpd/queue.c index 8669ae231ae..34fae8cee9e 100644 --- a/usr.sbin/smtpd/queue.c +++ b/usr.sbin/smtpd/queue.c @@ -1,4 +1,4 @@ -/* $OpenBSD: queue.c,v 1.96 2011/04/14 21:53:45 gilles Exp $ */ +/* $OpenBSD: queue.c,v 1.97 2011/04/14 22:36:09 gilles Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@openbsd.org> @@ -66,9 +66,9 @@ queue_imsg(struct smtpd *env, struct imsgev *iev, struct imsg *imsg) ss.code = 250; bzero(ss.u.msgid, sizeof ss.u.msgid); if (m->flags & F_MESSAGE_ENQUEUED) - ret = enqueue_create_layout(ss.u.msgid); + ret = queue_message_create(env, Q_ENQUEUE, ss.u.msgid); else - ret = queue_create_incoming_layout(ss.u.msgid); + ret = queue_message_create(env, Q_INCOMING, ss.u.msgid); if (ret == 0) ss.code = 421; imsg_compose_event(iev, IMSG_QUEUE_CREATE_MESSAGE, 0, 0, -1, @@ -85,12 +85,12 @@ queue_imsg(struct smtpd *env, struct imsgev *iev, struct imsg *imsg) case IMSG_QUEUE_COMMIT_MESSAGE: ss.id = m->session_id; if (m->flags & F_MESSAGE_ENQUEUED) { - if (enqueue_commit_message(m)) + if (queue_message_commit(env, Q_ENQUEUE, m->message_id)) env->stats->queue.inserts_local++; else ss.code = 421; } else { - if (queue_commit_incoming_message(m)) + if (queue_message_commit(env, Q_INCOMING, m->message_id)) env->stats->queue.inserts_remote++; else ss.code = 421; |