2009-07-09 Gonzalo Paniagua Javier <gonzalo@novell.com>
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Thu, 9 Jul 2009 17:11:30 +0000 (17:11 -0000)
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Thu, 9 Jul 2009 17:11:30 +0000 (17:11 -0000)
* SimpleWorkerRequest.cs: store the root web configuration path in a
static variable.

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

mcs/class/System.Web/System.Web.Hosting/ChangeLog
mcs/class/System.Web/System.Web.Hosting/SimpleWorkerRequest.cs

index cef9281584bdd0e7df50f2370d7eaf6802f06cb6..76006ec3549c7f0793c3f55a825b496897af09b0 100644 (file)
@@ -1,3 +1,8 @@
+2009-07-09 Gonzalo Paniagua Javier <gonzalo@novell.com>
+
+       * SimpleWorkerRequest.cs: store the root web configuration path in a
+       static variable.
+
 2009-02-19  Marek Habersack  <mhabersack@novell.com>
 
        * ApplicationHost.cs: added support for the
index f58209bcbfc307537997104363642bd6fe11b459..05c8ba5046fdd5c24c79aa2a0bef1117b6edcbfa 100644 (file)
@@ -57,7 +57,14 @@ namespace System.Web.Hosting {
                        
                // computed
                string raw_url;
-               
+
+               static readonly string root_web_config_path;
+
+               static SimpleWorkerRequest ()
+               {
+                       root_web_config_path = WebConfigurationManager.OpenWebConfiguration ("~").FilePath;
+               }
+
                //
                // Constructor used when the target application domain
                // was created with ApplicationHost.CreateApplicationHost
@@ -129,7 +136,7 @@ namespace System.Web.Hosting {
                }
 #if NET_2_0
                public override string RootWebConfigPath {
-                       get { return WebConfigurationManager.OpenWebConfiguration ("~").FilePath; }
+                       get { return root_web_config_path; }
                }
 #endif