httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject svn commit: r569204 - in /httpd/httpd/trunk/modules/experimental: config.m4 mod_rewrite_filter.c mod_sedfilter.c
Date Fri, 24 Aug 2007 00:54:16 GMT
Author: wrowe
Date: Thu Aug 23 17:54:15 2007
New Revision: 569204

URL: http://svn.apache.org/viewvc?rev=569204&view=rev
Log:
SEDFILTER has several anomolies; first, it's not SED syntax,
but more mod-rewrite like (and using the rewrite pcre parser).
Secondly, 'FILTER' in the filter name is redundant.  Simplify,
by renaming this 'REWRITE' filter.

Added:
    httpd/httpd/trunk/modules/experimental/mod_rewrite_filter.c
      - copied, changed from r568483, httpd/httpd/trunk/modules/experimental/mod_sedfilter.c
Removed:
    httpd/httpd/trunk/modules/experimental/mod_sedfilter.c
Modified:
    httpd/httpd/trunk/modules/experimental/config.m4

Modified: httpd/httpd/trunk/modules/experimental/config.m4
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/experimental/config.m4?rev=569204&r1=569203&r2=569204&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/experimental/config.m4 (original)
+++ httpd/httpd/trunk/modules/experimental/config.m4 Thu Aug 23 17:54:15 2007
@@ -4,6 +4,6 @@
 APACHE_MODULE(example, example and demo module, , , no)
 APACHE_MODULE(case_filter, example uppercase conversion filter, , , no)
 APACHE_MODULE(case_filter_in, example uppercase conversion input filter, , , no)
-APACHE_MODULE(sedfilter, response body sed-like filtering, , , no)
+APACHE_MODULE(rewrite_filter, response content rewrite-like filtering, , , no)
 
 APACHE_MODPATH_FINISH

Copied: httpd/httpd/trunk/modules/experimental/mod_rewrite_filter.c (from r568483, httpd/httpd/trunk/modules/experimental/mod_sedfilter.c)
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/experimental/mod_rewrite_filter.c?p2=httpd/httpd/trunk/modules/experimental/mod_rewrite_filter.c&p1=httpd/httpd/trunk/modules/experimental/mod_sedfilter.c&r1=568483&r2=569204&rev=569204&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/experimental/mod_sedfilter.c (original)
+++ httpd/httpd/trunk/modules/experimental/mod_rewrite_filter.c Thu Aug 23 17:54:15 2007
@@ -15,7 +15,7 @@
  */
 
 /*
- * mod_sedfilter.c: Perform sed-like rewriting on the fly
+ * mod_rewrite_filter.c: Perform content rewriting on the fly
  */
 
 #include "httpd.h"
@@ -31,9 +31,9 @@
 #define APR_WANT_STRFUNC
 #include "apr_want.h"
 
-static const char sedFilterName[] = "SEDFILTER";
+static const char rewrite_filter_name[] = "REWRITE";
 
-module AP_MODULE_DECLARE_DATA sedfilter_module;
+module AP_MODULE_DECLARE_DATA rewrite_filter_module;
 
 typedef struct {
     const apr_strmatch_pattern *pattern;
@@ -111,7 +111,7 @@
 
     sed_module_dcfg *cfg =
     (sed_module_dcfg *) ap_get_module_config(f->r->per_dir_config,
-                                             &sedfilter_module);
+                                             &rewrite_filter_module);
     sed_script *script;
 
     mybb = apr_brigade_create(f->r->pool, f->c->bucket_alloc);
@@ -513,7 +513,7 @@
 #define PROTO_FLAGS AP_FILTER_PROTO_CHANGE|AP_FILTER_PROTO_CHANGE_LENGTH
 static void register_hooks(apr_pool_t *pool)
 {
-    ap_register_output_filter(sedFilterName, sed_filter, NULL,
+    ap_register_output_filter(rewrite_filter_name, sed_filter, NULL,
                               AP_FTYPE_RESOURCE);
 }
 
@@ -523,7 +523,7 @@
     {NULL}
 };
 
-module AP_MODULE_DECLARE_DATA sedfilter_module = {
+module AP_MODULE_DECLARE_DATA rewrite_filter_module = {
     STANDARD20_MODULE_STUFF,
     create_sed_dcfg,            /* dir config creater */
     merge_sed_dcfg,             /* dir merger --- default is to override */



Mime
View raw message