mirror of
https://github.com/decke/smtprelay.git
synced 2025-12-26 07:12:29 -07:00
Move AddReceivedLine before further processing.
This commit is contained in:
4
main.go
4
main.go
@@ -170,6 +170,8 @@ func mailHandler(peer smtpd.Peer, env smtpd.Envelope) error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
env.AddReceivedLine(peer)
|
||||||
|
|
||||||
if *command != "" {
|
if *command != "" {
|
||||||
cmdLogger := logger.WithField("command", *command)
|
cmdLogger := logger.WithField("command", *command)
|
||||||
|
|
||||||
@@ -196,8 +198,6 @@ func mailHandler(peer smtpd.Peer, env smtpd.Envelope) error {
|
|||||||
|
|
||||||
logger.Info("delivering mail from peer using smarthost")
|
logger.Info("delivering mail from peer using smarthost")
|
||||||
|
|
||||||
env.AddReceivedLine(peer)
|
|
||||||
|
|
||||||
var sender string
|
var sender string
|
||||||
|
|
||||||
if *remoteSender == "" {
|
if *remoteSender == "" {
|
||||||
|
|||||||
Reference in New Issue
Block a user