james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b...@apache.org
Subject svn commit: r365694 - /james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java
Date Tue, 03 Jan 2006 17:53:19 GMT
Author: bago
Date: Tue Jan  3 09:53:16 2006
New Revision: 365694

URL: http://svn.apache.org/viewcvs?rev=365694&view=rev
Log:
Fixes message handling to be compliant with RFC and compatible with the latest patch to POP3
(see  	 JAMES-431)

Modified:
    james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java

Modified: james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java
URL: http://svn.apache.org/viewcvs/james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java?rev=365694&r1=365693&r2=365694&view=diff
==============================================================================
--- james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java (original)
+++ james/server/trunk/src/java/org/apache/james/smtpserver/DataCmdHandler.java Tue Jan  3
09:53:16 2006
@@ -17,29 +17,30 @@
 
 package org.apache.james.smtpserver;
 
-import org.apache.james.util.mail.dsn.DSNStatus;
 import org.apache.avalon.framework.logger.AbstractLogEnabled;
+import org.apache.james.Constants;
 import org.apache.james.core.MailHeaders;
 import org.apache.james.core.MailImpl;
+import org.apache.james.fetchmail.ReaderInputStream;
 import org.apache.james.util.CharTerminatedInputStream;
 import org.apache.james.util.DotStuffingInputStream;
+import org.apache.james.util.mail.dsn.DSNStatus;
 import org.apache.james.util.watchdog.BytesReadResetInputStream;
 import org.apache.mailet.MailAddress;
 import org.apache.mailet.RFC2822Headers;
 import org.apache.mailet.dates.RFC822DateFormat;
-import org.apache.james.Constants;
 
 import javax.mail.MessagingException;
 
 import java.io.ByteArrayInputStream;
-import java.io.SequenceInputStream;
 import java.io.IOException;
 import java.io.InputStream;
-
+import java.io.SequenceInputStream;
+import java.io.StringReader;
 import java.util.Collection;
-import java.util.List;
 import java.util.Date;
 import java.util.Enumeration;
+import java.util.List;
 
 
 /**
@@ -268,7 +269,8 @@
                 new MailImpl(session.getConfigurationData().getMailServer().getId(),
                              (MailAddress) session.getState().get(SENDER),
                              recipientCollection,
-                             new SequenceInputStream(headersIn, msgIn));
+                             new SequenceInputStream(new SequenceInputStream(headersIn, msgIn),
+                                     new ReaderInputStream(new StringReader("\r\n"))));
             // Call mail.getSize() to force the message to be
             // loaded. Need to do this to enforce the size limit
             if (session.getConfigurationData().getMaxMessageSize() > 0) {



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message