Overview
Features
Download
Documentation
Community
Add-Ons & Services

POP3 retrieave error

Please post support and help requests here.

POP3 retrieave error

Postby ImmortalDragon » 20 Dec 2013, 18:57

Version 1.4.6p2, windows7 x64, debian 7 x64.

Where is a problem in POP3ClientSession.
I've wrote a very simple program to retrieve a message.

Poco::Net::POP3ClientSession Session("pop.example.com");
Session.login("user@example.com", "password");

Session.listMessages(MailList);

Poco::Net::POP3ClientSession::MessageInfoVec::const_iterator It = MailList.begin();
Poco::Net::POP3ClientSession::MessageInfoVec::const_iterator ItEnd = MailList.end();

for (; It != ItEnd; ++It)
{
cout << (*It).id << endl;
try
{
Poco::Net::MailMessage Mail;
Session.retrieveMessage((*It).id, Mail);
cout << Mail.getSubject() << endl;
}
catch (Poco::Net::POP3Exception &e)
{
cout << e.displayText() << endl;
}
catch (Poco::Net::NetException &e)
{
cout << e.displayText() << endl;
}



}

After some mails begin exceptions:
POP3 Exception: Cannot get message list: some text from previews mail

For example: we have this mail:
1. Subject 1, Text1........EndText1.
2. Subject 2, Text2........EndText2.....part1.....something else.
3. Subject 3, Text3........EndText3.....part1.....something else.
4. Subject 4, Text4........EndText4.....part1.....something else.
5. Subject 5, Text4........EndText4.....part1.....something else.
6. Subject 6, Text4........EndText4.....part1.....something else.

After program i run i see this:
1
Subject 1
2
Subject 2
3
POP3 Exception: Cannot get message list
4
POP3 Exception: Cannot get message list: Text3........EndText3.....
5
POP3 Exception: Cannot get message list: ..part1.....something else
6
Subject 6

As i begin debug i look at this code: in function POP3ClientSession::retrieveMessage
after line: sendCommand("RETR", NumberFormatter::format(id), response);
response variable have not responce, but end of previews mail.
As i think - the mail message not retrieve some part of the message, and on the next - it continue to retrieve previews.
ImmortalDragon
 
Posts: 1
Joined: 20 Dec 2013, 18:53

Return to Support

Who is online

Users browsing this forum: No registered users and 2 guests

cron