Author: markt Date: Mon Jun 19 17:00:15 2017 New Revision: 1799231 URL: http://svn.apache.org/viewvc?rev=1799231&view=rev Log: Remove unnecessary code
Modified: tomcat/trunk/java/org/apache/coyote/Response.java Modified: tomcat/trunk/java/org/apache/coyote/Response.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/Response.java?rev=1799231&r1=1799230&r2=1799231&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/coyote/Response.java (original) +++ tomcat/trunk/java/org/apache/coyote/Response.java Mon Jun 19 17:00:15 2017 @@ -124,11 +124,6 @@ public final class Response { */ Exception errorException = null; - /** - * Has the charset been explicitly set. - */ - boolean charsetSet = false; - Request req; // ------------------------------------------------------------- Properties @@ -431,7 +426,6 @@ public final class Response { } this.charset = charset; - charsetSet = true; } @@ -478,7 +472,6 @@ public final class Response { if (charsetValue.length() > 0) { try { charset = B2CConverter.getCharset(charsetValue); - charsetSet = true; } catch (UnsupportedEncodingException e) { log.warn(sm.getString("response.encoding.invalid", charsetValue), e); } @@ -495,8 +488,7 @@ public final class Response { String ret = contentType; if (ret != null - && charset != null - && charsetSet) { + && charset != null) { ret = ret + ";charset=" + charset.name(); } @@ -542,7 +534,6 @@ public final class Response { contentLanguage = null; locale = DEFAULT_LOCALE; charset = null; - charsetSet = false; contentLength = -1; status = 200; message = null; --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org