[Mono-bugs] [Bug 73539][Wis] Changed - System.Environment.OSVersion reports wrong version

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 11 Mar 2005 10:24:15 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by sebastien@ximian.com.

http://bugzilla.ximian.com/show_bug.cgi?id=73539

--- shadow/73539	2005-03-11 07:15:12.000000000 -0500
+++ shadow/73539.tmp.29780	2005-03-11 10:24:15.000000000 -0500
@@ -1,10 +1,10 @@
 Bug#: 73539
 Product: Mono: Class Libraries
-Version: 1.1
-OS: GNU/Linux [Other]
+Version: 1.0
+OS: unknown
 OS Details: ArchLinux 0.7
 Status: NEEDINFO   
 Resolution: 
 Severity: Unknown
 Priority: Wishlist
 Component: CORLIB
@@ -71,6 +71,39 @@
 Unix 2.6.0.0
 [vinay@one09 ~]$ uname -a
 Linux one09 2.6.10 #1 Wed Feb 9 18:29:45 IST 2005 i686 Intel(R)
 Pentium(R) 4 CPU 1.70GHz GenuineIntel GNU/Linux
 
 btw, its mono 1.1.4
+
+------- Additional Comments From sebastien@ximian.com  2005-03-11 10:24 -------
+Probably a parsing bug in Version.CreateFromString. Could you try this
+sample and report back the values. Thanks
+
+---8<---8<---8<---8<---8<----
+using System.Runtime.CompilerServices;
+using System.Text;
+
+namespace System {
+
+	public class Environment {
+
+		[MethodImplAttribute (MethodImplOptions.InternalCall)]
+		internal static extern string GetOSVersionString ();
+
+		public static void Main ()
+		{
+			string os = GetOSVersionString ();
+			Console.WriteLine (os);
+			Console.WriteLine (BitConverter.ToString (Encoding.UTF8.GetBytes
+(os)));
+		}
+	}
+}
+---8<---8<---8<---8<---8<----
+
+Results should look like:
+
+> mono bug73539b.exe
+2.6.8-717.inotify.4-default
+32-2E-36-2E-38-2D-37-31-37-2E-69-6E-6F-74-69-66-79-2E-34-2D-64-65-66-61-75-6C-74
+