summaryrefslogtreecommitdiffabout
path: root/kmicromail
authorzautrix <zautrix>2005-03-24 11:29:53 (UTC)
committer zautrix <zautrix>2005-03-24 11:29:53 (UTC)
commitb9e83e4536ee4fc34b882fb88b8e5fd00bfdf929 (patch) (side-by-side diff)
treea0a5565360abc8e79d417b2e55f9b179ad615b87 /kmicromail
parent1dff93853802953ed92b24ac18ebf57f39dcbcfe (diff)
downloadkdepimpi-b9e83e4536ee4fc34b882fb88b8e5fd00bfdf929.zip
kdepimpi-b9e83e4536ee4fc34b882fb88b8e5fd00bfdf929.tar.gz
kdepimpi-b9e83e4536ee4fc34b882fb88b8e5fd00bfdf929.tar.bz2
ompi smtp fix
Diffstat (limited to 'kmicromail') (more/less context) (ignore whitespace changes)
-rw-r--r--kmicromail/libmailwrapper/smtpwrapper.cpp22
1 files changed, 16 insertions, 6 deletions
diff --git a/kmicromail/libmailwrapper/smtpwrapper.cpp b/kmicromail/libmailwrapper/smtpwrapper.cpp
index 448a2e9..a6c12e4 100644
--- a/kmicromail/libmailwrapper/smtpwrapper.cpp
+++ b/kmicromail/libmailwrapper/smtpwrapper.cpp
@@ -219,6 +219,7 @@ void SMTPwrapper::connect_server()
we can not display any messagebox */
return;
}
+ //m_smtp->auth = MAILSMTP_AUTH_LOGIN;
int err = MAILSMTP_NO_ERROR;
; // odebug << "Servername " << server << " at port " << port << "" << oendl;
@@ -252,19 +253,28 @@ void SMTPwrapper::connect_server()
try_tls = false;
qDebug("Smpt: No TLS possible ");
} else {
- err = mailesmtp_ehlo(m_smtp);
- if ( err != MAILSMTP_NO_ERROR )
- result = 0;
- else
- qDebug("Smpt: Using TLS ");
+ qDebug("Smpt: Using TLS ");
}
}
+
//qDebug("mailesmtp_ehlo %d ",err );
if (!try_tls && force_tls) {
result = 0;
failuretext = i18n("Error init SMTP tls:%1").arg(mailsmtpError(err));
+ }
+ if ( mailesmtp_ehlo(m_smtp) != MAILSMTP_NO_ERROR ) {
+ qDebug("Smpt: ehlo failed ");
+ result = 0;
}
-
+ else {
+ //qDebug("Smpt: auth is %d -- %d %d",m_smtp->auth, MAILSMTP_AUTH_LOGIN, MAILSMTP_AUTH_PLAIN);
+ if ( m_smtp->auth & MAILSMTP_AUTH_LOGIN && m_smtp->auth & MAILSMTP_AUTH_PLAIN ) {
+ qDebug("Smpt: Using MAILSMTP_AUTH_LOGIN ");
+ m_smtp->auth -= MAILSMTP_AUTH_PLAIN;
+ //qDebug("Smpt: auth is %d -- %d %d",m_smtp->auth, MAILSMTP_AUTH_LOGIN, MAILSMTP_AUTH_PLAIN);
+ }
+ }
+
if (result==1 && m_SmtpAccount->getLogin() ) {
; // odebug << "smtp with auth" << oendl;
if ( m_SmtpAccount->getUser().isEmpty() || m_SmtpAccount->getPassword().isEmpty() ) {