Commits

dr...@81dbac14-341a-0410-aa85-cbcd92e6f43e  committed 5fa56f2

Issue number: CACHE-38, CACHE-159
Submitted by: Andres March

Corrected the use of the character encoding in the getWriter call. This should work even with gzipped contents.

  • Participants
  • Parent commits 3a80e2c

Comments (0)

Files changed (1)

File src/core/java/com/opensymphony/oscache/web/filter/CacheHttpServletResponseWrapper.java

      */
     public PrintWriter getWriter() throws IOException {
         if (cachedWriter == null) {
-            String encoding = result.getContentEncoding();
+            String encoding = getCharacterEncoding();
             if (encoding != null) {
                 cachedWriter = new PrintWriter(new OutputStreamWriter(getOutputStream(), encoding));
             } else { // using the default character encoding