X-Git-Url: http://git.home-dn.net/?p=manu%2Fmod-proxy-html.git;a=blobdiff_plain;f=mod_proxy_html.c;h=0215cb24c5e056551bbaf334c2b3bbbed4ecbc29;hp=dfdbf60d5b3dd03a51223bbad7eda02bd140e7cc;hb=e23d1bdf874c2af6d7ab54fa834da653cc75c6cc;hpb=7254aa90316b0f07c538db96cb6a1740654c9a74
diff --git a/mod_proxy_html.c b/mod_proxy_html.c
index dfdbf60..0215cb2 100644
--- a/mod_proxy_html.c
+++ b/mod_proxy_html.c
@@ -88,7 +88,7 @@ typedef struct urlmap {
unsigned int flags ;
union {
const char* c ;
- regex_t* r ;
+ ap_regex_t* r ;
} from ;
const char* to ;
} urlmap ;
@@ -208,7 +208,7 @@ static void dump_content(saxctxt* ctx) {
size_t match ;
char c = 0 ;
int nmatch ;
- regmatch_t pmatch[10] ;
+ ap_regmatch_t pmatch[10] ;
char* subs ;
size_t len, offs ;
#ifndef GO_FASTER
@@ -323,7 +323,7 @@ static void pstartElement(void* ctxt, const xmlChar* name,
char* found ;
saxctxt* ctx = (saxctxt*) ctxt ;
size_t nmatch ;
- regmatch_t pmatch[10] ;
+ ap_regmatch_t pmatch[10] ;
#ifndef GO_FASTER
int verbose = ctx->cfg->verbose ;
#endif
@@ -580,18 +580,18 @@ static htmlSAXHandlerPtr setupSAX(apr_pool_t* pool) {
return sax ;
}
-static regex_t* seek_meta_ctype ;
-static regex_t* seek_charset ;
-static regex_t* seek_meta ;
+static ap_regex_t* seek_meta_ctype ;
+static ap_regex_t* seek_charset ;
+static ap_regex_t* seek_meta ;
static void proxy_html_child_init(apr_pool_t* pool, server_rec* s) {
seek_meta_ctype = ap_pregcomp(pool,
"(]*http-equiv[ \t\r\n='\"]*content-type[^>]*>)",
- REG_EXTENDED|REG_ICASE) ;
+ AP_REG_EXTENDED|AP_REG_ICASE) ;
seek_charset = ap_pregcomp(pool, "charset=([A-Za-z0-9_-]+)",
- REG_EXTENDED|REG_ICASE) ;
+ AP_REG_EXTENDED|AP_REG_ICASE) ;
seek_meta = ap_pregcomp(pool, "]*(http-equiv)[^>]*>",
- REG_EXTENDED|REG_ICASE) ;
+ AP_REG_EXTENDED|AP_REG_ICASE) ;
}
static xmlCharEncoding sniff_encoding(request_rec* r, const char* cbuf, size_t bytes
@@ -603,7 +603,7 @@ static xmlCharEncoding sniff_encoding(request_rec* r, const char* cbuf, size_t b
char* encoding = NULL ;
char* p ;
char* q ;
- regmatch_t match[2] ;
+ ap_regmatch_t match[2] ;
unsigned char* buf = (unsigned char*)cbuf ;
VERBOSE( ap_log_rerror(APLOG_MARK, APLOG_INFO, 0, r,
@@ -673,7 +673,7 @@ static meta* metafix(request_rec* r, const char* buf /*, size_t bytes*/
const char* q ;
char* header ;
char* content ;
- regmatch_t pmatch[2] ;
+ ap_regmatch_t pmatch[2] ;
char delim ;
while ( ! ap_regexec(seek_meta, buf+offs, 2, pmatch, 0) ) {
@@ -942,10 +942,10 @@ static const char* set_urlmap(cmd_parms* cmd, void* CFG,
newmap->to = apr_pstrdup(cmd->pool, to) ;
} else {
regflags
- = REGFLAG(REG_EXTENDED,flags,'x')
- | REGFLAG(REG_ICASE,flags,'i')
- | REGFLAG(REG_NOSUB,flags,'n')
- | REGFLAG(REG_NEWLINE,flags,'s')
+ = REGFLAG(AP_REG_EXTENDED,flags,'x')
+ | REGFLAG(AP_REG_ICASE,flags,'i')
+ | REGFLAG(AP_REG_NOSUB,flags,'n')
+ | REGFLAG(AP_REG_NEWLINE,flags,'s')
;
newmap->from.r = ap_pregcomp(cmd->pool, from, regflags) ;
newmap->to = apr_pstrdup(cmd->pool, to) ;