writeTo in Multipart forgets the boundary-prefix
------------------------------------------------
Key: MIME4J-39
URL: https://issues.apache.org/jira/browse/MIME4J-39
Project: Mime4j
Issue Type: Bug
Reporter: Aljoscha Rittner
Current implementation (in Multipart.writeTo):
for (int i = 0; i < bodyParts.size(); i++) {
writer.write(boundary + "\r\n");
((BodyPart) bodyParts.get(i)).writeTo(out);
}
But we need:
for (int i = 0; i < bodyParts.size(); i++) {
writer.write("--" + boundary + "\r\n");
writer.flush();
((BodyPart) bodyParts.get(i)).writeTo(out);
}
Every starting boundary needs a prefix "--". (and we need the flush for the
BufferedWriter).
Without this prefix, it's impossible to read Multipart-Messages.
best regards,
josh.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]