httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 33892] - escape char ( \) in regexps in SSI exprs is automatically doubled.
Date Tue, 08 Mar 2005 21:35:31 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=33892>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=33892





------- Additional Comments From rjf@cs.rice.edu  2005-03-08 22:35 -------
There was one additional unescaped slash in my previous comment.
I fixed that and made the changes to all the other places
where this occured.  I'm back in business.

Regarding the need to escape /'s when they're inside a character
class such as [^/] --  In the past, it wasn't necessary to escape
this specifically because the / is hidden in the character class.
but this requires actually parsing the guts of the r.e. rather than
just a quick scan for unescaped /'s.  As I initially
said, this worked for 5 years until we moved to the new environment.

Is this standard behavior?  Don't know, but there's lots of documentation
like "man perlrequick" out there that say things like:

  Character classes also have ordinary and special characters, but the sets
  of ordinary and special characters inside a character class are different
  than those outside a character class.  The special characters for a char-
  acter class are "-]\^$" and are matched using an escape:

Or from the PCRE documentation:

     Part of a pattern that is in square brackets  is  called  a  "character
       class". In a character class the only metacharacters are:

         \      general escape character
         ^      negate the class, but only if the first character
         -      indicates character range
         [      POSIX character class (only if followed by POSIX
                  syntax)
         ]      terminates the character class

Taking the "only" in the above literally always worked in the past.
I've never seen a description that contradicted this.


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message