[Mono-bugs] [Bug 39925][Nor] New - Problems using CultureInfo.CurrentCulture.CompareInfo.Compare

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
Tue, 18 Mar 2003 16:34:04 -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 carlosga@telefonica.net.

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

--- shadow/39925	Tue Mar 18 16:34:04 2003
+++ shadow/39925.tmp.25152	Tue Mar 18 16:34:04 2003
@@ -0,0 +1,59 @@
+Bug#: 39925
+Product: Mono/MCS
+Version: unspecified
+OS: Red Hat 8.0
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: Misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: carlosga@telefonica.net               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Problems using CultureInfo.CurrentCulture.CompareInfo.Compare
+
+Hello:
+
+
+I'm getting an exception whgen i try to use
+CultureInfo.CurrentCulture.CompareInfo.Compare in Mono under Linux Red Hat 8.0:
+
+
+TestCase:
+
+using System;
+using System.Globalization;
+
+namespace Test
+{
+	public class CultureInfoTest
+	{
+		public static void Main(string[] args)
+		{
+			string strA = "@col_key";
+			string strB = "@col_key";
+
+			/* This raises the next exception using Mono on Linux Red Hat 8 and works 
+			 * well on Windows using csc.
+			 * 
+			 * Unhandled Exception: System.NullReferenceException: 
+			 * A null value was found where an object instance was required
+			 * in <0x0005c> 00 Test.CultureInfoTest:Main (string[])
+			 */
+			CultureInfo.CurrentCulture.CompareInfo.Compare(strA, strB, 
+				CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | 
+				CompareOptions.IgnoreCase);
+		}
+	}
+}
+
+
+
+
+Best regards
+Carlos Guzmán Álvarez
+Vigo-Spain