Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Add the message id in log #37

Merged
merged 1 commit into from

2 participants

@tpoindessous

There is no message id in logfile so it's difficult to debug a message sent through qpsmtpd.

@tpoindessous tpoindessous Add the message id in log
There is no message id in logfile so it's difficult to debug a message sent through qpsmtpd.
9f404f5
@msimerson msimerson merged commit 941fac9 into smtpd:master

1 check passed

Details default The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 24, 2014
  1. @tpoindessous

    Add the message id in log

    tpoindessous authored
    There is no message id in logfile so it's difficult to debug a message sent through qpsmtpd.
This page is out of date. Refresh to see the latest.
Showing with 5 additions and 1 deletion.
  1. +5 −1 plugins/queue/smtp-forward
View
6 plugins/queue/smtp-forward
@@ -73,7 +73,11 @@ sub hook_queue {
or return (DECLINED, "Unable to queue message ($!)");
}
$smtp->dataend() or return (DECLINED, "Unable to queue message ($!)");
+ my $qid = $smtp->message();
+ my @list = split(' ', $qid);
+ $qid = pop(@list);
+
$smtp->quit() or return (DECLINED, "Unable to queue message ($!)");
$self->log(LOGINFO, "finished queueing");
- return (OK, "Queued!");
+ return (OK, "queued as $qid");
}
Something went wrong with that request. Please try again.