author | harlekin <harlekin> | 2004-01-06 12:33:20 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2004-01-06 12:33:20 (UTC) |
commit | a1270a04613d9adbd72c41ae1cde4683b036eebd (patch) (unidiff) | |
tree | 0ba4084bb84bd7e9e75fe1918f5b0b5cf0059410 /noncore/net/mail/libmailwrapper | |
parent | 1c484a5dfcea2e7e3dc4774c706ca03cab229d40 (diff) | |
download | opie-a1270a04613d9adbd72c41ae1cde4683b036eebd.zip opie-a1270a04613d9adbd72c41ae1cde4683b036eebd.tar.gz opie-a1270a04613d9adbd72c41ae1cde4683b036eebd.tar.bz2 |
less icons
Diffstat (limited to 'noncore/net/mail/libmailwrapper') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/mail/libmailwrapper/pop3wrapper.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/noncore/net/mail/libmailwrapper/pop3wrapper.cpp b/noncore/net/mail/libmailwrapper/pop3wrapper.cpp index ec4dcd2..cceb22e 100644 --- a/noncore/net/mail/libmailwrapper/pop3wrapper.cpp +++ b/noncore/net/mail/libmailwrapper/pop3wrapper.cpp | |||
@@ -38,9 +38,9 @@ RecBody POP3wrapper::fetchBody( const RecMail &mail ) | |||
38 | { | 38 | { |
39 | int err = MAILPOP3_NO_ERROR; | 39 | int err = MAILPOP3_NO_ERROR; |
40 | char *message = 0; | 40 | char *message = 0; |
41 | size_t length = 0; | 41 | size_t length = 0; |
42 | 42 | ||
43 | login(); | 43 | login(); |
44 | if ( !m_pop3 ) { | 44 | if ( !m_pop3 ) { |
45 | return RecBody(); | 45 | return RecBody(); |
46 | } | 46 | } |
@@ -50,13 +50,13 @@ RecBody POP3wrapper::fetchBody( const RecMail &mail ) | |||
50 | if (mail.Msgsize()>HARD_MSG_SIZE_LIMIT) { | 50 | if (mail.Msgsize()>HARD_MSG_SIZE_LIMIT) { |
51 | qDebug("Message to large: %i",mail.Msgsize()); | 51 | qDebug("Message to large: %i",mail.Msgsize()); |
52 | return body; | 52 | return body; |
53 | } | 53 | } |
54 | 54 | ||
55 | QFile msg_cache(msgTempName); | 55 | QFile msg_cache(msgTempName); |
56 | 56 | ||
57 | cleanMimeCache(); | 57 | cleanMimeCache(); |
58 | 58 | ||
59 | if (mail.getNumber()!=last_msg_id) { | 59 | if (mail.getNumber()!=last_msg_id) { |
60 | if (msg_cache.exists()) { | 60 | if (msg_cache.exists()) { |
61 | msg_cache.remove(); | 61 | msg_cache.remove(); |
62 | } | 62 | } |
@@ -87,13 +87,13 @@ RecBody POP3wrapper::fetchBody( const RecMail &mail ) | |||
87 | msg_data->msg_message = message; | 87 | msg_data->msg_message = message; |
88 | msg_data->msg_length = strlen(message); | 88 | msg_data->msg_length = strlen(message); |
89 | } | 89 | } |
90 | body = parseMail(mailmsg); | 90 | body = parseMail(mailmsg); |
91 | 91 | ||
92 | /* clean up */ | 92 | /* clean up */ |
93 | if (mailmsg) mailmessage_free(mailmsg); | 93 | if (mailmsg) mailmessage_free(mailmsg); |
94 | if (message) free(message); | 94 | if (message) free(message); |
95 | 95 | ||
96 | return body; | 96 | return body; |
97 | } | 97 | } |
98 | 98 | ||
99 | void POP3wrapper::listMessages(const QString &, QList<RecMail> &target ) | 99 | void POP3wrapper::listMessages(const QString &, QList<RecMail> &target ) |
@@ -152,8 +152,9 @@ void POP3wrapper::login() | |||
152 | return; | 152 | return; |
153 | } | 153 | } |
154 | err = mailfolder_connect(m_folder); | 154 | err = mailfolder_connect(m_folder); |
155 | if (err != MAIL_NO_ERROR) { | 155 | if (err != MAIL_NO_ERROR) { |
156 | qDebug( QString( "FEHLERNUMMER %1" ).arg( err ) ); | ||
156 | Global::statusMessage(tr("Error initializing folder")); | 157 | Global::statusMessage(tr("Error initializing folder")); |
157 | mailfolder_free(m_folder); | 158 | mailfolder_free(m_folder); |
158 | m_folder = 0; | 159 | m_folder = 0; |
159 | mailstorage_free(m_pop3); | 160 | mailstorage_free(m_pop3); |
@@ -213,9 +214,9 @@ int POP3wrapper::deleteAllMail(const Folder*) | |||
213 | Global::statusMessage(tr("Error deleting mail %1").arg(i+1)); | 214 | Global::statusMessage(tr("Error deleting mail %1").arg(i+1)); |
214 | res=0; | 215 | res=0; |
215 | } | 216 | } |
216 | break; | 217 | break; |
217 | } | 218 | } |
218 | return res; | 219 | return res; |
219 | } | 220 | } |
220 | 221 | ||
221 | void POP3wrapper::statusFolder(folderStat&target_stat,const QString&) | 222 | void POP3wrapper::statusFolder(folderStat&target_stat,const QString&) |
@@ -236,9 +237,9 @@ encodedString* POP3wrapper::fetchRawBody(const RecMail&mail) | |||
236 | encodedString*res = 0; | 237 | encodedString*res = 0; |
237 | mailmessage * mailmsg = 0; | 238 | mailmessage * mailmsg = 0; |
238 | int err = mailsession_get_message(m_folder->fld_session, mail.getNumber(), &mailmsg); | 239 | int err = mailsession_get_message(m_folder->fld_session, mail.getNumber(), &mailmsg); |
239 | err = mailmessage_fetch(mailmsg,&target,&length); | 240 | err = mailmessage_fetch(mailmsg,&target,&length); |
240 | if (mailmsg) mailmessage_free(mailmsg); | 241 | if (mailmsg) mailmessage_free(mailmsg); |
241 | if (target) { | 242 | if (target) { |
242 | res = new encodedString(target,length); | 243 | res = new encodedString(target,length); |
243 | } | 244 | } |
244 | return res; | 245 | return res; |