2010-06-29 Marek Safar <marek.safar@gmail.com>
[mono.git] / mcs / class / System / System.Net.Configuration / ConnectionManagementHandler.cs
index a2690cfb1863c159241a1e85a79724fe1377a1ce..42a0d5afb7583832643a0cadd4e791a2d6f0c458 100644 (file)
@@ -32,6 +32,8 @@ using System.Collections;
 using System.Configuration;
 #if (XML_DEP)
 using System.Xml;
+#else
+using XmlNode = System.Object;
 #endif
 
 namespace System.Net.Configuration
@@ -43,8 +45,8 @@ namespace System.Net.Configuration
                
                public ConnectionManagementData (object parent)
                {
-                       data = new Hashtable (CaseInsensitiveHashCodeProvider.Default,
-                                             CaseInsensitiveComparer.Default);
+                       data = new Hashtable (CaseInsensitiveHashCodeProvider.DefaultInvariant,
+                                             CaseInsensitiveComparer.DefaultInvariant);
                        if (parent != null && parent is ConnectionManagementData) {
                                ConnectionManagementData p = (ConnectionManagementData) parent;
                                foreach (string k in p.data.Keys)
@@ -95,11 +97,10 @@ namespace System.Net.Configuration
 
        class ConnectionManagementHandler : IConfigurationSectionHandler
        {
-#if (XML_DEP)
                public virtual object Create (object parent, object configContext, XmlNode section)
                {
                        ConnectionManagementData cmd = new ConnectionManagementData (parent);
-                       
+#if (XML_DEP)                  
                        if (section.Attributes != null && section.Attributes.Count != 0)
                                HandlersUtil.ThrowException ("Unrecognized attribute", section);
 
@@ -144,10 +145,10 @@ namespace System.Net.Configuration
 
                                HandlersUtil.ThrowException ("Unexpected element", child);
                        }
+#endif                 
 
                        return cmd;
                }
-#endif
        }
 
        internal class HandlersUtil