Skip to content

Commit

Permalink
Issue jetty#3916 - Don't add blank lines after multipart boundaries
Browse files Browse the repository at this point in the history
  • Loading branch information
seanbright committed Nov 1, 2019
1 parent 9cede68 commit 4618811
Showing 1 changed file with 6 additions and 2 deletions.
Expand Up @@ -110,8 +110,10 @@ public void startPart(String contentType)
out.write(boundaryBytes);
out.write(__CRLF);
if (contentType != null)
{
out.write(("Content-Type: " + contentType).getBytes(StandardCharsets.ISO_8859_1));
out.write(__CRLF);
out.write(__CRLF);
}
out.write(__CRLF);
}

Expand All @@ -132,8 +134,10 @@ public void startPart(String contentType, String[] headers)
out.write(boundaryBytes);
out.write(__CRLF);
if (contentType != null)
{
out.write(("Content-Type: " + contentType).getBytes(StandardCharsets.ISO_8859_1));
out.write(__CRLF);
out.write(__CRLF);
}
for (int i = 0; headers != null && i < headers.length; i++)
{
out.write(headers[i].getBytes(StandardCharsets.ISO_8859_1));
Expand Down

0 comments on commit 4618811

Please sign in to comment.