Commit ad02aeb1 authored by Nick Kew's avatar Nick Kew
Browse files

Backport trawick's mod_charset_lite patch


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@404847 13f79535-47bb-0310-9956-ffa450edef68
parent afddbf51
Loading
Loading
Loading
Loading
+3 −0
Changes for CHANGES: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
                                                        -*- coding: utf-8 -*-
Changes with Apache 2.2.3
  *) mod_charset_lite: Bypass translation when the source and dest charsets
     are the same. [Jeff Trawick]
Changes with Apache 2.2.2
  *) mod_deflate: work correctly in an internal redirect
+0 −11
Changes for STATUS: 0 added lines, 11 removed lines.
Original line number Diff line number Diff line
@@ -76,17 +76,6 @@ RELEASE SHOWSTOPPERS:
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
  [ start all new proposals below, under PATCHES PROPOSED. ]

    * Remove odd DECLINED code from mod_charset_lite filter.
      http://svn.apache.org/viewcvs?rev=399665&view=rev
      +1 trawick, rpluem, niq
      niq: This is right, but the underlying behaviour (refuse to
      work in a proxy) is bad.  There's a TODO.

    * mod_charset_lite: Don't go through the motions of translating if
      the source and dest charsets are the same.
      http://svn.apache.org/viewcvs?rev=399668&view=rev
      +1 trawick, rpluem, niq

PATCHES PROPOSED TO BACKPORT FROM TRUNK:

    * Backport mod_authz_dbd (it's had some testing now)
+2 −3
Changes for modules/filters/mod_charset_lite.c: 2 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -232,6 +232,8 @@ static int find_code_page(request_rec *r)
    if (!strncmp(r->filename, "gone:", 5)) return DECLINED;
    if (!strncmp(r->filename, "passthrough:", 12)) return DECLINED;
    if (!strncmp(r->filename, "forbidden:", 10)) return DECLINED;
    /* no translation when server and network charsets are set to the same value */
    if (!strcasecmp(dc->charset_source, dc->charset_default)) return DECLINED;

    mime_type = r->content_type ? r->content_type : ap_default_type(r);

@@ -821,9 +823,6 @@ static apr_status_t xlate_out_filter(ap_filter_t *f, apr_bucket_brigade *bb)
        }
    }

    /* catch proxy requests */
    if (f->r->proxyreq) return DECLINED;

    /* Opening the output translation (this used to be done in the fixup hook,
     * but that was too early: a subsequent type modification, e.g., by a
     * CGI script, would go unnoticed. Now we do it in the filter itself.)