author | groucho <groucho> | 2003-04-24 11:19:11 (UTC) |
---|---|---|
committer | groucho <groucho> | 2003-04-24 11:19:11 (UTC) |
commit | 9671975e21266e3bfa6f3c793a3278b67cea34b7 (patch) (unidiff) | |
tree | 876c77939cfd0e00fc844b1b5af09b2978564a6d /noncore/unsupported/mailit/popclient.cpp | |
parent | 51e782b9658de61dc02579e115a9c62f396609a3 (diff) | |
download | opie-9671975e21266e3bfa6f3c793a3278b67cea34b7.zip opie-9671975e21266e3bfa6f3c793a3278b67cea34b7.tar.gz opie-9671975e21266e3bfa6f3c793a3278b67cea34b7.tar.bz2 |
- reworked size filtering
- started reworking offline download
- better tab focus switching
- Hello "Whats this" capability
- Fixed parsing of To: header files (no more Delivered-To: and Reply-To: matches)
- Good bye Settings.txt, hello Config Objects and encrypted passwords
- Translation improvements (added trs)
- Parser optimizations
Diffstat (limited to 'noncore/unsupported/mailit/popclient.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/unsupported/mailit/popclient.cpp | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/noncore/unsupported/mailit/popclient.cpp b/noncore/unsupported/mailit/popclient.cpp index f9cc337..67306be 100644 --- a/noncore/unsupported/mailit/popclient.cpp +++ b/noncore/unsupported/mailit/popclient.cpp | |||
@@ -120,5 +120,4 @@ void PopClient::incomingData() | |||
120 | 120 | ||
121 | response = socket->readLine(); | 121 | response = socket->readLine(); |
122 | //qDebug(response +" %d", status); | ||
123 | 122 | ||
124 | switch(status) { | 123 | switch(status) { |
@@ -132,16 +131,6 @@ void PopClient::incomingData() | |||
132 | timeStamp = response.mid( start , end - start + 1); | 131 | timeStamp = response.mid( start , end - start + 1); |
133 | md5Source = timeStamp + popPassword; | 132 | md5Source = timeStamp + popPassword; |
134 | //qDebug( md5Source); | ||
135 | // for( int i = 0; i < md5Source.length(); i++) { | ||
136 | // buff[i] = (QChar)md5Source[i]; | ||
137 | // } | ||
138 | 133 | ||
139 | md5_buffer( (char const *)md5Source, md5Source.length(),&md5Digest[0]); | 134 | md5_buffer( (char const *)md5Source, md5Source.length(),&md5Digest[0]); |
140 | // md5_buffer(char const *buffer, unsigned int len, char *digest); | ||
141 | |||
142 | // MD5_Init( &ctx); | ||
143 | // MD5_Update( &ctx, buff, sizeof( buff) ); | ||
144 | // MD5_Final( md5Digest, &ctx); | ||
145 | // MD5( buff, md5Source.length(), md5Digest); | ||
146 | 135 | ||
147 | for(int j =0;j < MD5_DIGEST_LENGTH ;j++) | 136 | for(int j =0;j < MD5_DIGEST_LENGTH ;j++) |
@@ -165,5 +154,5 @@ void PopClient::incomingData() | |||
165 | break; | 154 | break; |
166 | } | 155 | } |
167 | //password shhh. don't tell anyone (implement APOP...) | 156 | |
168 | case Pass: { | 157 | case Pass: { |
169 | *stream << "PASS " << popPassword << "\r\n"; | 158 | *stream << "PASS " << popPassword << "\r\n"; |
@@ -249,8 +238,9 @@ void PopClient::incomingData() | |||
249 | case Retr: { | 238 | case Retr: { |
250 | if (status != Quit) { | 239 | if (status != Quit) { |
251 | if (!preview || mailSize <= headerLimit) { | 240 | if (mailSize <= headerLimit) |
241 | { | ||
252 | *stream << "RETR " << messageCount << "\r\n"; | 242 | *stream << "RETR " << messageCount << "\r\n"; |
253 | } else { //only header | 243 | } else { //only header |
254 | *stream << "TOP " << messageCount << " 0\r\n"; | 244 | *stream << "TOP " << messageCount << " 0\r\n"; |
255 | } | 245 | } |
256 | messageCount++; | 246 | messageCount++; |
@@ -284,6 +274,8 @@ void PopClient::incomingData() | |||
284 | } else { //message reach entire size | 274 | } else { //message reach entire size |
285 | //complete mail downloaded | 275 | //complete mail downloaded |
286 | if ( (!preview ) || ((preview) && (mailSize <= headerLimit)) ){ | 276 | //if ( (!preview ) || ((preview) && (mailSize <= headerLimit)) ){ |
287 | emit newMessage(message, messageCount-1, mailSize, TRUE); | 277 | if ( mailSize <= headerLimit) |
278 | { | ||
279 | emit newMessage(message, messageCount-1, mailSize, TRUE); | ||
288 | } else { //incomplete mail downloaded | 280 | } else { //incomplete mail downloaded |
289 | emit newMessage(message, messageCount-1, mailSize, FALSE); | 281 | emit newMessage(message, messageCount-1, mailSize, FALSE); |