]> granicus.if.org Git - apache/commitdiff
Merge r1299783 from trunk:
authorJim Jagielski <jim@apache.org>
Fri, 27 Apr 2012 13:06:38 +0000 (13:06 +0000)
committerJim Jagielski <jim@apache.org>
Fri, 27 Apr 2012 13:06:38 +0000 (13:06 +0000)
some more trace logging for AddOutputFilterByType

Submitted by: sf
Reviewed/backported by: jim

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1331412 13f79535-47bb-0310-9956-ffa450edef68

STATUS
modules/filters/mod_filter.c

diff --git a/STATUS b/STATUS
index b2bbd2565567912b3a47428549d9af1833d61507..571ed0ed345af7151fa57c0513eb26491a7c734b 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -109,11 +109,6 @@ PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
     2.4 patch: Trunk patch works
     +1: sf, jorton, jim
 
-  * mod_filter: Add some trace logging for AddOutputFilterByType
-    Trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1299783
-    2.4 patch: Trunk patch works
-    +1: sf, jorton, jim
-
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
   [ New proposals should be added at the end of the list ]
 
index 7dd7db1abb7eee71205788c2128b6af714d9a410..67cfd6bbc332f4fd687b90ed48b3e736f9f1da40 100644 (file)
@@ -165,13 +165,21 @@ static int filter_lookup(ap_filter_t *f, ap_filter_rec_t *filter)
             const char **type = provider->types;
             size_t len = strcspn(r->content_type, "; \t");
             AP_DEBUG_ASSERT(type != NULL);
+            ap_log_rerror(APLOG_MARK, APLOG_TRACE4, 0, r,
+                          "Content-Type '%s' ...", r->content_type);
             while (*type) {
                 /* Handle 'content-type;charset=...' correctly */
                 if (strncmp(*type, r->content_type, len) == 0
                     && (*type)[len] == '\0') {
+                    ap_log_rerror(APLOG_MARK, APLOG_TRACE4, 0, r,
+                                  "... matched '%s'", *type);
                     match = 1;
                     break;
                 }
+                else {
+                    ap_log_rerror(APLOG_MARK, APLOG_TRACE4, 0, r,
+                                  "... did not match '%s'", *type);
+                }
                 type++;
             }
             ap_log_rerror(APLOG_MARK, APLOG_TRACE2, 0, r,
@@ -179,6 +187,11 @@ static int filter_lookup(ap_filter_t *f, ap_filter_rec_t *filter)
                           provider->frec->name,
                           match ? "matched" : "did not match");
         }
+        else {
+            ap_log_rerror(APLOG_MARK, APLOG_TRACE2, 0, r,
+                          "Content-Type condition for '%s' did not match: "
+                          "no Content-Type", provider->frec->name);
+        }
 
         if (match) {
             /* condition matches this provider */