]> git.ipfire.org Git - people/ms/dma.git/commitdiff
dma: don't set it->mailf too early
authorSimon Schubert <corecode@dragonflybsd.org>
Tue, 25 Aug 2009 00:22:04 +0000 (02:22 +0200)
committerSimon Schubert <corecode@dragonflybsd.org>
Tue, 25 Aug 2009 00:24:39 +0000 (02:24 +0200)
We may not set it->mailf in newspoolf(), or aquirespool() will not
(re-)open the mail file, leading to concurrent seeks.

Reported-by: Daniel Roethlisberger
DragonFly-Bug: <http://bugs.dragonflybsd.org/issue1462>

spool.c

diff --git a/spool.c b/spool.c
index 9a74620220ce7364ca5a2845427a636c14569102..33e972d5082b7f7f9e8cee50b62e8421fc535fa6 100644 (file)
--- a/spool.c
+++ b/spool.c
@@ -101,7 +101,6 @@ newspoolf(struct queue *queue, const char *sender)
        hdrlen = ftello(queue->mailf);
 
        LIST_FOREACH(it, &queue->queue, next) {
-               it->mailf = queue->mailf;
                it->hdrlen = hdrlen;
        }