mail/isync: Resolve "unexpected EOF" SSL error
Fixes an issue where some IMAP servers, such as Gmail, do not send a
close notification (SSL_shutdown()) before closing the TCP socket,
leading to "unexpected EOF" errors with OpenSSL 3.0.
Now mbsync gracefully handles this scenario, preventing the following
error:
Socket error: secure read from imap.gmail.com ([IPv6 Address
Redacted]:993): error:0A000126:SSL routines::unexpected eof while
reading
PR: 274604
(cherry picked from commit a4ef2ba2e61e3a4190f04c889ded4f6688163354)