Fix a bug when connect to the SMTP server over SSH