You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ni...@apache.org on 2010/09/21 20:52:04 UTC
svn commit: r999541 - /httpd/httpd/trunk/server/util_regex.c
Author: niq
Date: Tue Sep 21 18:52:03 2010
New Revision: 999541
URL: http://svn.apache.org/viewvc?rev=999541&view=rev
Log:
Remove cruft that accidentally got into r999533
Modified:
httpd/httpd/trunk/server/util_regex.c
Modified: httpd/httpd/trunk/server/util_regex.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/util_regex.c?rev=999541&r1=999540&r2=999541&view=diff
==============================================================================
--- httpd/httpd/trunk/server/util_regex.c (original)
+++ httpd/httpd/trunk/server/util_regex.c Tue Sep 21 18:52:03 2010
@@ -134,7 +134,6 @@ AP_DECLARE(int) ap_rxplus_exec(apr_pool_
const char *pattern, char **newpattern)
//int max_iterations)
{
-#if 1
int ret = 1;
int startl, oldl, newl, diffsz;
const char *remainder;
@@ -173,61 +172,6 @@ AP_DECLARE(int) ap_rxplus_exec(apr_pool_
*newpattern = subs;
}
return ret;
-
-
-
-
-#else
-
-
-
-
-
-
-
-
-
-
-
-
- if (!(rx->flags & AP_REG_MULTI) || (rx->subs == NULL)) {
- max_iterations = 1;
- }
- /* FIXME: multi-matching is incorrect */
- while (max_iterations-- > 0) {
- if (ap_regexec(&rx->rx, pattern, rx->nmatch, rx->pmatch, rx->flags)
- == 0) {
- ret++;
- if (rx->subs) {
- rx->match = pattern;
- *newpattern = ap_pregsub(pool, rx->subs, pattern,
- rx->nmatch, rx->pmatch);
- pattern = *newpattern;
- if (pattern == NULL) {
- max_iterations = 0;
- }
- }
- }
- else {
- max_iterations = 0;
- }
- }
-
- if (ret == 0 || rx->flags&AP_REG_NOMEM) {
- rx->match = NULL; /* no match, so don't pretend to remember a match */
- }
- else {
-#if 0
- /* FIXME - should we be 'safe' and take the performance hit,
- * or just document thou-shalt-keep-pattern-in-scope?
- */
- if (rx->match == inpattern) {
- rx->match = apr_pstrdup(pool, inpattern);
- }
-#endif
- }
- return ret;
-#endif
}
#ifdef DOXYGEN
AP_DECLARE(int) ap_rxplus_nmatch(ap_rxplus_t *rx)