emersion / go-imap

📥 An IMAP library for clients and servers
MIT License
2.02k stars 288 forks source link

Set timeout for Dial() #597

Closed 64chevy closed 3 months ago

64chevy commented 3 months ago

Sometimes the connection stays for infinite time and doesn't give any error or timeout. Is there no way to set connection timeout for non-TLS dialer?

Not sure how client.Timeout can help because its set later after the dialer is connected.

emersion commented 3 months ago

Eh right, completely forgot about this, a9d7ec54a300 should help.