Fixed content length bug

This commit is contained in:
CalDescent 2021-12-21 16:15:20 +00:00
parent 83d5bf45e5
commit 8caec81d1e

View File

@ -96,7 +96,7 @@ public class ArbitraryDataRenderer {
HTMLParser htmlParser = new HTMLParser(resourceId, inPath, prefix, usePrefix, data); HTMLParser htmlParser = new HTMLParser(resourceId, inPath, prefix, usePrefix, data);
htmlParser.replaceRelativeLinks(filename); htmlParser.replaceRelativeLinks(filename);
response.setContentType(context.getMimeType(filename)); response.setContentType(context.getMimeType(filename));
response.setContentLength(data.length); response.setContentLength(htmlParser.getData().length);
response.getOutputStream().write(htmlParser.getData()); response.getOutputStream().write(htmlParser.getData());
} }
else { else {