Author: ajith
Date: Mon May 15 04:27:11 2006
New Revision: 406615

URL: http://svn.apache.org/viewcvs?rev=406615&view=rev
Log:
Modified the MIMEPartInputStream to correctly process the combinations of CR 
/LF/ --. this error caused the MTOMized streams to drop the CR/LF when present 
with -- inside the content. See Jira issue 699

Modified:
    
webservices/commons/trunk/modules/axiom/src/org/apache/axiom/attachments/MIMEBodyPartInputStream.java

Modified: 
webservices/commons/trunk/modules/axiom/src/org/apache/axiom/attachments/MIMEBodyPartInputStream.java
URL: 
http://svn.apache.org/viewcvs/webservices/commons/trunk/modules/axiom/src/org/apache/axiom/attachments/MIMEBodyPartInputStream.java?rev=406615&r1=406614&r2=406615&view=diff
==============================================================================
--- 
webservices/commons/trunk/modules/axiom/src/org/apache/axiom/attachments/MIMEBodyPartInputStream.java
 (original)
+++ 
webservices/commons/trunk/modules/axiom/src/org/apache/axiom/attachments/MIMEBodyPartInputStream.java
 Mon May 15 04:27:11 2006
@@ -65,7 +65,7 @@
                     return 13;
                 }
             }
-        } else if ((byte) value != boundary[0]) {
+        } else {
             return value;
         }
 
@@ -100,8 +100,10 @@
         if (value != -1) { // Stream might have ended
             inStream.unread(value);
         }
-        inStream.unread(boundary, 1, boundaryIndex - 1);
-        return boundary[0];
+
+        inStream.unread(boundary, 0, boundaryIndex);
+        inStream.unread(10);
+        return 13;
     }
     
     public boolean getBoundaryStatus()


Reply via email to