james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n...@apache.org
Subject cvs commit: james-server/src/java/org/apache/james/smtpserver SMTPHandler.java
Date Sat, 08 May 2004 02:28:30 GMT
noel        2004/05/07 19:28:30

  Modified:    src/java/org/apache/james/smtpserver Tag: branch_2_1_fcs
                        SMTPHandler.java
  Log:
  Fix for JAMES-281.  Emit a separate Return-Path: header for each header in the original
message.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.35.4.19 +9 -2      james-server/src/java/org/apache/james/smtpserver/SMTPHandler.java
  
  Index: SMTPHandler.java
  ===================================================================
  RCS file: /home/cvs/james-server/src/java/org/apache/james/smtpserver/SMTPHandler.java,v
  retrieving revision 1.35.4.18
  retrieving revision 1.35.4.19
  diff -u -r1.35.4.18 -r1.35.4.19
  --- SMTPHandler.java	16 Apr 2004 02:23:36 -0000	1.35.4.18
  +++ SMTPHandler.java	8 May 2004 02:28:30 -0000	1.35.4.19
  @@ -1365,7 +1365,14 @@
           Enumeration headerLines = headers.getAllHeaderLines();
           MailHeaders newHeaders = new MailHeaders();
           // Put the Return-Path first
  -        newHeaders.addHeaderLine(RFC2822Headers.RETURN_PATH + ": " + returnPath);
  +        // JAMES-281 fix for messages that improperly have multiple
  +        // Return-Path headers
  +        StringTokenizer tokenizer = new StringTokenizer(returnPath, "\r\n");
  +        while(tokenizer.hasMoreTokens()) {
  +            String path = tokenizer.nextToken();
  +            newHeaders.addHeaderLine(RFC2822Headers.RETURN_PATH + ": " + path);
  +        }
  +
           // Put our Received header next
           headerLineBuffer.append(RFC2822Headers.RECEIVED + ": from ")
                           .append(remoteHost)
  
  
  

---------------------------------------------------------------------
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