我可以发誓这段代码几天前就可以工作了。我正在使用来自http://trixy.justinkbeck.com/2009/07/c-pop3-library-with-ssl-for-gmail.html的 SSL 二进制文件
POPClient client = new POPClient("pop.gmail.com", 995, "user@gmail.com", "qwerty", AuthenticationMethod.USERPASS, true);
int unread = client.GetMessageCount();
for (int i = 0; i < unread; i++)
{
Message m = client.GetMessage(i + 1, true);
Console.WriteLine(m.Subject);
if (m.HasAttachment)
{
Attachment a = m.GetAttachment(1);
// Problem! HasAttachment flag is set, but there's no attachments in the collection!
m.SaveAttachment(a, a.ContentFileName);
}
}
client.QUIT();
但是今天,我可以阅读邮件,但附件是空的。我在想中国的惨败让他们改变了一些东西。想法?