2008-02-28 Marek Habersack <mhabersack@novell.com>
authorMarek Habersack <grendel@twistedcode.net>
Thu, 28 Feb 2008 13:14:20 +0000 (13:14 -0000)
committerMarek Habersack <grendel@twistedcode.net>
Thu, 28 Feb 2008 13:14:20 +0000 (13:14 -0000)
        * HandlerFactoryConfiguration.cs: ignore case when matching
        handler paths.
2008-02-28  Marek Habersack  <mhabersack@novell.com>

        * HttpHandlerAction.cs: ignore case when matching handler
        paths. Fixes bug #364995
2008-02-28  Marek Habersack  <mhabersack@novell.com>

        * TemplateControlParser.cs: when registering a control, check for
        the .ascx extension case-insensitively. Fixes bug #364995

svn path=/trunk/mcs/; revision=96870

mcs/class/System.Web/System.Web.Configuration/ChangeLog
mcs/class/System.Web/System.Web.Configuration/FileMatchingInfo.cs
mcs/class/System.Web/System.Web.Configuration/HandlerFactoryConfiguration.cs
mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog
mcs/class/System.Web/System.Web.Configuration_2.0/HttpHandlerAction.cs
mcs/class/System.Web/System.Web.UI/ChangeLog
mcs/class/System.Web/System.Web.UI/TemplateControlParser.cs

index 866f75b0cc216c5ada18461694369a5e03895217..818436edf340aea9d46ba6802c341212e732192e 100644 (file)
@@ -1,3 +1,11 @@
+2008-02-28  Marek Habersack  <mhabersack@novell.com>
+
+       * HandlerFactoryConfiguration.cs: ignore case when matching
+       handler paths.
+
+       * FileMatchingInfo.cs: regular expression is created with the
+       ignore case option.
+
 2007-12-13  Marek Habersack  <mhabersack@novell.com>
 
        * FileMatchingInfo.cs. MachineKeyRegistryStorage.cs: speed
index d8113db5aa90da3f319a0ad84d104fa2f37c74a9..3b2ab25c9126d8d4b8ceabf584c66e1ef9bf3976 100644 (file)
@@ -71,7 +71,7 @@ namespace System.Web.Configuration
                                        expr = expr.Substring (1);
 
                                expr += "\\z";
-                               RegExp = new Regex (expr);
+                               RegExp = new Regex (expr, RegexOptions.IgnoreCase);
                        }
                }
        }
index 0456babbacdec9b534c2d8675fd46f873b08011f..e8971f846a7fee3504bb85be679439d069a20fe8 100644 (file)
@@ -102,10 +102,10 @@ namespace System.Web.Configuration {
                                FileMatchingInfo fm = files [j];
 
                                if (fm.MatchExact != null)
-                                       return fm.MatchExact.Length == orig.Length && StrUtils.EndsWith (orig, fm.MatchExact);
+                                       return fm.MatchExact.Length == orig.Length && StrUtils.EndsWith (orig, fm.MatchExact, true);
                                        
                                if (fm.EndsWith != null)
-                                       return StrUtils.EndsWith (p, fm.EndsWith);
+                                       return StrUtils.EndsWith (p, fm.EndsWith, true);
 
                                if (fm.MatchExpr == "*")
                                        return true;
index b1cc7882d571cf7452e58d9d2a540500b9d42fea..450c8f3b4f5a9ffcbd1ed3521563ecd6b4be210d 100644 (file)
@@ -1,3 +1,8 @@
+2008-02-28  Marek Habersack  <mhabersack@novell.com>
+
+       * HttpHandlerAction.cs: ignore case when matching handler
+       paths. Fixes bug #364995
+
 2008-02-26  Marek Habersack  <mhabersack@novell.com>
 
        * BuildProviderCollection.cs: be case-insensitive when looking for
index 09ce7c259eb767526136e9fd1707b55094eb7e06..213c28724192abc4fc981a8342c56b13cbe71892 100644 (file)
@@ -182,12 +182,6 @@ namespace System.Web.Configuration
                                        return cachedMatches [pathToMatch];
 
                                bool result = false;
-                               bool ignoreCase =
-#if TARGET_J2EE
-                                       true;
-#else
-                                       false;
-#endif
                                string[] handlerPaths = Path.Split (',');
                                int slash = pathToMatch.LastIndexOf ('/');
                                string origPathToMatch = pathToMatch;
@@ -227,7 +221,7 @@ namespace System.Web.Configuration
 
                                        if (matchExact != null)
                                        {
-                                               result = matchExact.Length == origPathToMatch.Length && StrUtils.EndsWith (origPathToMatch, matchExact, ignoreCase);
+                                               result = matchExact.Length == origPathToMatch.Length && StrUtils.EndsWith (origPathToMatch, matchExact, true);
                                                if (result == true)
                                                        break;
                                                else
@@ -235,7 +229,7 @@ namespace System.Web.Configuration
                                        }
                                        else if (endsWith != null)
                                        {
-                                               result = StrUtils.EndsWith (pathToMatch, endsWith, ignoreCase);
+                                               result = StrUtils.EndsWith (pathToMatch, endsWith, true);
                                                if (result == true)
                                                        break;
                                                else
@@ -249,7 +243,7 @@ namespace System.Web.Configuration
                                                        expr = expr.Substring (1);
 
                                                expr += "\\z";
-                                               regEx = new Regex (expr);
+                                               regEx = new Regex (expr, RegexOptions.IgnoreCase);
 
                                                if (regEx.IsMatch (origPathToMatch))
                                                {
index 8a44895bed1a842ef198ff3b0da3e2ed636d35e7..5cb8488ec6085462c9f9341c49db67bc52b8bf0d 100644 (file)
@@ -1,10 +1,14 @@
+2008-02-28  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlParser.cs: when registering a control, check for
+       the .ascx extension case-insensitively. Fixes bug #364995
+
 2008-02-28 Igor Zelmanovich <igorz@mainsoft.com>
 
        * Control.cs:
        fixed exception propagation in case of multiple control with same id
        were found.      
 
-
 2008-02-26  Marek Habersack  <mhabersack@novell.com>
 
        * TemplateParser.cs: a better error message.
index 3a2c253d985ef695bed8e207af8739d5f4cc4317..b2b0b2423ef4003026ebd366f1e7926108a94509 100644 (file)
@@ -150,7 +150,7 @@ namespace System.Web.UI {
                                if (tagname != null && src == null)
                                        ThrowParseException ("Need a Src attribute with TagName.");
 
-                               if (!src.EndsWith (".ascx"))
+                               if (!StrUtils.EndsWith (src, ".ascx", true))
                                        ThrowParseException ("Source file extension for controls must be .ascx");
 
                                RegisterCustomControl (tagprefix, tagname, src);