when switching from Writer to OutputStream.
The special handling of this case in the
DefaultServlet was broken due to a MIME type
change for JavaScript.
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@
1139280 13f79535-47bb-0310-9956-
ffa450edef68
// trying to serve a text file
if ( (contentType == null)
|| (contentType.startsWith("text"))
- || (contentType.endsWith("xml")) ) {
+ || (contentType.endsWith("xml"))
+ || (contentType.contains("/javascript")) ) {
writer = response.getWriter();
// Cannot reliably serve partial content with a Writer
ranges = FULL;
<update>
Improve JMX unit test. (rjung)
</update>
+ <fix>
+ Fix IllegalStateException for JavaScript files when switching from
+ Writer to OutputStream. The special handling of this case in the
+ DefaultServlet was broken due to a MIME type change for JavaScript.
+ (funkman)
+ </fix>
</changelog>
</subsection>
<subsection name="Coyote">