Team,
When trying to send an e-mail using `smtp.SendMail()' through GMail, I am getting the error "wrong host name". Looking at the sources, I see that the check fails when the server identifies itself with a name different from that given to `smtp.PlainAuth()'. In the case of GMail (as could be the case with several other providers too), the CNAME entries probably result in the server identifying itself with one of the aliases.
Have others encountered this error, or am I doing something incorrectly? Here is a small program that results in this error. Thanks.
Greetings,
JS
* * * *
/mnt/hgfs/mac/tmp/go$ cat g.go
package main
import (
"bytes"
"log"
"smtp"
)
func main() {
msg := bytes.NewBufferString("Test - 1")
if err != nil {
log.Println("!! Send failure :", err)
}
}