Diffstat (limited to 'noncore/unsupported/mailit/emailhandler.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/unsupported/mailit/emailhandler.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/noncore/unsupported/mailit/emailhandler.cpp b/noncore/unsupported/mailit/emailhandler.cpp index 39f693d..5b8bda1 100644 --- a/noncore/unsupported/mailit/emailhandler.cpp +++ b/noncore/unsupported/mailit/emailhandler.cpp | |||
@@ -35,32 +35,32 @@ Enclosure* EnclosureList::dupl(Enclosure *in) | |||
35 | { | 35 | { |
36 | ac = new Enclosure(*in); | 36 | ac = new Enclosure(*in); |
37 | return ac; | 37 | return ac; |
38 | } | 38 | } |
39 | 39 | ||
40 | EmailHandler::EmailHandler() | 40 | EmailHandler::EmailHandler() |
41 | { | 41 | { |
42 | qDebug("EMailHandler::EmailHandler"); | 42 | qDebug("EMailHandler::EmailHandler"); |
43 | 43 | ||
44 | smtpClient = new SmtpClient(); | 44 | smtpClient = new SmtpClient(); |
45 | popClient = new PopClient(); | 45 | popClient = new PopClient(); |
46 | 46 | ||
47 | connect(smtpClient, SIGNAL(errorOccurred(int)), this, | 47 | connect(smtpClient, SIGNAL(errorOccurred(int, const QString &)), this, |
48 | SIGNAL(smtpError(int)) ); | 48 | SIGNAL(smtpError(int, const QString &)) ); |
49 | connect(smtpClient, SIGNAL(mailSent()), this, SIGNAL(mailSent()) ); | 49 | connect(smtpClient, SIGNAL(mailSent()), this, SIGNAL(mailSent()) ); |
50 | connect(smtpClient, SIGNAL(updateStatus(const QString &)), this, | 50 | connect(smtpClient, SIGNAL(updateStatus(const QString &)), this, |
51 | SIGNAL(updateSmtpStatus(const QString &)) ); | 51 | SIGNAL(updateSmtpStatus(const QString &)) ); |
52 | 52 | ||
53 | connect(popClient, SIGNAL(errorOccurred(int)), this, | 53 | connect(popClient, SIGNAL(errorOccurred(int, const QString &)), this, |
54 | SIGNAL(popError(int)) ); | 54 | SIGNAL(popError(int, const QString &)) ); |
55 | connect(popClient, SIGNAL(newMessage(const QString &, int, uint, bool)), | 55 | connect(popClient, SIGNAL(newMessage(const QString &, int, uint, bool)), |
56 | this, SLOT(messageArrived(const QString &, int, uint, bool)) ); | 56 | this, SLOT(messageArrived(const QString &, int, uint, bool)) ); |
57 | connect(popClient, SIGNAL(updateStatus(const QString &)), this, | 57 | connect(popClient, SIGNAL(updateStatus(const QString &)), this, |
58 | SIGNAL(updatePopStatus(const QString &)) ); | 58 | SIGNAL(updatePopStatus(const QString &)) ); |
59 | connect(popClient, SIGNAL(mailTransfered(int)), this, | 59 | connect(popClient, SIGNAL(mailTransfered(int)), this, |
60 | SIGNAL(mailTransfered(int)) ); | 60 | SIGNAL(mailTransfered(int)) ); |
61 | 61 | ||
62 | 62 | ||
63 | //relaying size information | 63 | //relaying size information |
64 | connect(popClient, SIGNAL(currentMailSize(int)), | 64 | connect(popClient, SIGNAL(currentMailSize(int)), |
65 | this, SIGNAL(currentMailSize(int)) ); | 65 | this, SIGNAL(currentMailSize(int)) ); |
66 | connect(popClient, SIGNAL(downloadedSize(int)), | 66 | connect(popClient, SIGNAL(downloadedSize(int)), |
@@ -153,25 +153,25 @@ bool EmailHandler::parse(const QString &in, const QString &lineShift, Email *mai | |||
153 | QString temp, boundary; | 153 | QString temp, boundary; |
154 | int pos; | 154 | int pos; |
155 | QString delimiter, header, body, mimeHeader, mimeBody; | 155 | QString delimiter, header, body, mimeHeader, mimeBody; |
156 | QString content, contentType, contentAttribute, id, encoding; | 156 | QString content, contentType, contentAttribute, id, encoding; |
157 | QString fileName, storedName; | 157 | QString fileName, storedName; |
158 | int enclosureId = 0; | 158 | int enclosureId = 0; |
159 | 159 | ||
160 | mail->rawMail = in; | 160 | mail->rawMail = in; |
161 | mail->received = TRUE; | 161 | mail->received = TRUE; |
162 | mail->files.setAutoDelete(TRUE); | 162 | mail->files.setAutoDelete(TRUE); |
163 | 163 | ||
164 | temp = lineShift + "." + lineShift; | 164 | temp = lineShift + "." + lineShift; |
165 | 165 | ||
166 | if (in.right(temp.length()) != temp) { | 166 | if (in.right(temp.length()) != temp) { |
167 | mail->rawMail += temp; | 167 | mail->rawMail += temp; |
168 | } | 168 | } |
169 | 169 | ||
170 | 170 | ||
171 | delimiter = lineShift + lineShift; // "\n\n" or "\r\n\r\n" | 171 | delimiter = lineShift + lineShift; // "\n\n" or "\r\n\r\n" |
172 | pos = in.find(delimiter, 0, FALSE); | 172 | pos = in.find(delimiter, 0, FALSE); |
173 | header = in.left(pos); | 173 | header = in.left(pos); |
174 | body = in.right(in.length() - pos - delimiter.length()); | 174 | body = in.right(in.length() - pos - delimiter.length()); |
175 | if ((body.at(body.length()-2) == '.') && (body.at(body.length()-3) == '\n')) | 175 | if ((body.at(body.length()-2) == '.') && (body.at(body.length()-3) == '\n')) |
176 | body.truncate(body.length()-2); | 176 | body.truncate(body.length()-2); |
177 | 177 | ||