summaryrefslogtreecommitdiffabout
path: root/kmicromail/libmailwrapper
Unidiff
Diffstat (limited to 'kmicromail/libmailwrapper') (more/less context) (ignore whitespace changes)
-rw-r--r--kmicromail/libmailwrapper/imapwrapper.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/kmicromail/libmailwrapper/imapwrapper.cpp b/kmicromail/libmailwrapper/imapwrapper.cpp
index 09e52b8..4f0c849 100644
--- a/kmicromail/libmailwrapper/imapwrapper.cpp
+++ b/kmicromail/libmailwrapper/imapwrapper.cpp
@@ -44,13 +44,12 @@ int IMAPwrapper::selectMbox(const QString&mbox)
44 m_Lastmbox = mbox; 44 m_Lastmbox = mbox;
45 return err; 45 return err;
46} 46}
47 47
48void IMAPwrapper::imap_progress( size_t current, size_t maximum ) 48void IMAPwrapper::imap_progress( size_t current, size_t maximum )
49{ 49{
50 qApp->processEvents();
51 return; 50 return;
52 //qDebug("imap progress %d of %d ",current,maximum ); 51 //qDebug("imap progress %d of %d ",current,maximum );
53 //Global::statusMessage(i18n("Downloading message %1 of %2").arg( current).arg(maximum)); 52 //Global::statusMessage(i18n("Downloading message %1 of %2").arg( current).arg(maximum));
54 //qApp->processEvents() 53 //qApp->processEvents()
55 static unsigned int last = 0; 54 static unsigned int last = 0;
56 if ( last != current ) 55 if ( last != current )
@@ -155,13 +154,12 @@ void IMAPwrapper::login(bool tryTLS) // = true)
155 return; 154 return;
156 } 155 }
157 } else { 156 } else {
158 user = account->getUser(); 157 user = account->getUser();
159 pass = account->getPassword(); 158 pass = account->getPassword();
160 } 159 }
161
162 m_imap = mailimap_new( 20, &imap_progress ); 160 m_imap = mailimap_new( 20, &imap_progress );
163 161
164 /* connect */ 162 /* connect */
165 bool ssl = false; 163 bool ssl = false;
166 bool try_tls = false; 164 bool try_tls = false;
167 bool force_tls = false; 165 bool force_tls = false;
@@ -171,15 +169,15 @@ void IMAPwrapper::login(bool tryTLS) // = true)
171 } 169 }
172 if (account->ConnectionType()==1) { 170 if (account->ConnectionType()==1) {
173 force_tls = true; 171 force_tls = true;
174 } 172 }
175 173
176 if ( ssl ) { 174 if ( ssl ) {
177 qDebug("using ssl "); 175 //qDebug("using ssl ");
178 err = mailimap_ssl_connect( m_imap, (char*)server.latin1(), port ); 176 err = mailimap_ssl_connect( m_imap, (char*)server.latin1(), port );
179 qDebug("back "); 177 //qDebug("back ");
180 } else { 178 } else {
181 err = mailimap_socket_connect( m_imap, (char*)server.latin1(), port ); 179 err = mailimap_socket_connect( m_imap, (char*)server.latin1(), port );
182 } 180 }
183 181
184 if ( err != MAILIMAP_NO_ERROR && 182 if ( err != MAILIMAP_NO_ERROR &&
185 err != MAILIMAP_NO_ERROR_AUTHENTICATED && 183 err != MAILIMAP_NO_ERROR_AUTHENTICATED &&