Author: spouliot
Date: 2005-05-09 16:03:23 -0400 (Mon, 09 May 2005)
New Revision: 44298

Modified:
   trunk/mcs/class/System.Web/System.Web/HttpRuntime.cs
Log:
Check platform without using #define

Modified: trunk/mcs/class/System.Web/System.Web/HttpRuntime.cs
===================================================================
--- trunk/mcs/class/System.Web/System.Web/HttpRuntime.cs        2005-05-09 
20:00:22 UTC (rev 44297)
+++ trunk/mcs/class/System.Web/System.Web/HttpRuntime.cs        2005-05-09 
20:03:23 UTC (rev 44298)
@@ -435,11 +435,11 @@
                public static bool IsOnUNCShare {
                        get {
                                // IsUnc broken under unix?
-#if NET_2_0
-                               return (Environment.OSVersion.Platform != 
PlatformID.Unix &&
-#else
-                               return (!((int) Environment.OSVersion.Platform 
== 128) &&
-#endif
+
+                               // check for non-Unix platforms - see FAQ for 
more details
+                               // 
http://www.mono-project.com/FAQ:_Technical#How_to_detect_the_execution_platform_.3F
+                               int platform = (int) 
Environment.OSVersion.Platform;
+                               return ((platform != 4) && (platform != 128) &&
                                        new Uri ("file://" + 
ClrInstallDirectory).IsUnc);
                        }
                }

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to