summaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorYves Fischer <yvesf+git@xapek.org>2021-02-18 23:42:07 +0100
committerYves Fischer <yvesf+git@xapek.org>2021-02-18 23:42:07 +0100
commit8a530eb8139e9cb235355b80d9cbfdaa6b2c2e43 (patch)
treef8e985c475cded6bf7581ab265c7cda111d0f3d4 /main.go
parentc440fdac0c6637069d41fc8fd3506ec31e52a469 (diff)
downloadsmtp-forward-8a530eb8139e9cb235355b80d9cbfdaa6b2c2e43.tar.gz
smtp-forward-8a530eb8139e9cb235355b80d9cbfdaa6b2c2e43.zip
logmsg
Diffstat (limited to 'main.go')
-rw-r--r--main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/main.go b/main.go
index d32fb01..e561c1e 100644
--- a/main.go
+++ b/main.go
@@ -91,7 +91,7 @@ func forward(targetEmail string, data []byte) error {
err = smtp.SendMail(mxes[0].Host+":25", nil, `forwarder@localnet.cc`, []string{targetEmail}, builder.Bytes())
if err, ok := err.(*textproto.Error); ok {
if 400 <= err.Code && err.Code < 500 {
- log.Printf(`retry sleep 120s count=%v code=%v`, retryCount, err.Code)
+ log.Printf(`retry sleep 120s count=%v code=%v msg=%v`, retryCount, err.Code, err.Msg)
time.Sleep(120 * time.Second)
retryCount--
continue