summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Faurot <eric@cvs.openbsd.org>2013-10-27 18:21:08 +0000
committerEric Faurot <eric@cvs.openbsd.org>2013-10-27 18:21:08 +0000
commit84f498004229c9c6c0083552560df968dad57b32 (patch)
tree8e08031bfb908feaffc1d2347f7cf4c017d9728b
parent5f60b9a81a0fae116b264d74c68405a893fa8616 (diff)
obvious fixes in the external queue code.
work-in-progress: not supported yet.
-rw-r--r--usr.sbin/smtpd/queue_api.c3
-rw-r--r--usr.sbin/smtpd/queue_proc.c4
2 files changed, 4 insertions, 3 deletions
diff --git a/usr.sbin/smtpd/queue_api.c b/usr.sbin/smtpd/queue_api.c
index 6484c3578fa..ca5e929b742 100644
--- a/usr.sbin/smtpd/queue_api.c
+++ b/usr.sbin/smtpd/queue_api.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: queue_api.c,v 1.2 2013/10/26 12:27:59 eric Exp $ */
+/* $OpenBSD: queue_api.c,v 1.3 2013/10/27 18:21:07 eric Exp $ */
/*
* Copyright (c) 2013 Eric Faurot <eric@openbsd.org>
@@ -149,6 +149,7 @@ queue_msg_dispatch(void)
/* XXX needs more love */
r = -1;
+ snprintf(path, sizeof path, "/tmp/message.XXXXXXXXXX");
fd = mkstemp(path);
if (fd == -1) {
log_warn("warn: queue-api: mkstemp");
diff --git a/usr.sbin/smtpd/queue_proc.c b/usr.sbin/smtpd/queue_proc.c
index ffedce5bd99..24efd905f96 100644
--- a/usr.sbin/smtpd/queue_proc.c
+++ b/usr.sbin/smtpd/queue_proc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: queue_proc.c,v 1.1 2013/07/19 20:37:07 eric Exp $ */
+/* $OpenBSD: queue_proc.c,v 1.2 2013/10/27 18:21:07 eric Exp $ */
/*
* Copyright (c) 2013 Eric Faurot <eric@openbsd.org>
@@ -126,7 +126,7 @@ queue_proc_message_create(uint32_t *msgid)
queue_proc_call();
queue_proc_read(&r, sizeof(r));
if (r == 1)
- queue_proc_read(msgid, sizeof(msgid));
+ queue_proc_read(msgid, sizeof(*msgid));
queue_proc_end();
return (r);