From: Chris Jaekl Date: Sun, 1 Nov 2015 01:55:05 +0000 (+0900) Subject: SendMail: after '.' that terminates "DATA", send only one CRLF, not two. X-Git-Url: https://jaekl.net/gitweb/?a=commitdiff_plain;h=3183929a888a2105d57815fb37001a72efaec003;p=cfb.git SendMail: after '.' that terminates "DATA", send only one CRLF, not two. --- diff --git a/prod/net/jaekl/qd/util/SendMail.java b/prod/net/jaekl/qd/util/SendMail.java index 1f56302..68befa7 100644 --- a/prod/net/jaekl/qd/util/SendMail.java +++ b/prod/net/jaekl/qd/util/SendMail.java @@ -129,7 +129,7 @@ public class SendMail { sendMimeParts(pw); - String result = sendLine(pw, br, "\r\n.\r\n"); + String result = sendLine(pw, br, "\r\n."); return result; } diff --git a/test/net/jaekl/qd/util/SendMailTest.java b/test/net/jaekl/qd/util/SendMailTest.java index 5d942cb..b7c64ef 100644 --- a/test/net/jaekl/qd/util/SendMailTest.java +++ b/test/net/jaekl/qd/util/SendMailTest.java @@ -56,7 +56,7 @@ public class SendMailTest { + "Tarzan\r\n" + "\r\n" + "--snip_snip--\r\n" - + "\r\n.\r\n\r\n" + + "\r\n.\r\n" + "QUIT\r\n"; SmtpConversationMock conversat = new SmtpConversationMock(TYPICAL_INIT, TYPICAL);