[Mono-bugs] [Bug 55822][Nor] New - U_ILLEGAL_ARGUMENT_ERROR when looking up or replacing null character in string on Windows
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Fri, 19 Mar 2004 15:05:23 -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 gert.driesen@pandora.be.
http://bugzilla.ximian.com/show_bug.cgi?id=55822
--- shadow/55822 2004-03-19 15:05:23.000000000 -0500
+++ shadow/55822.tmp.12278 2004-03-19 15:05:23.000000000 -0500
@@ -0,0 +1,47 @@
+Bug#: 55822
+Product: Mono: Runtime
+Version: unspecified
+OS:
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: misc
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: gert.driesen@pandora.be
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: U_ILLEGAL_ARGUMENT_ERROR when looking up or replacing null character in string on Windows
+
+When replacing a null character (\0) in a string on Windows, the result is
+a null value.
+
+The following message is also output :
+
+** Message: : usearch_open error: U_ILLEGAL_ARGUMENT_ERROR
+
+You can reproduce this on Windows using the following code snippet :
+
+using System;
+
+namespace NullCharReplace {
+ public class EntryPoint {
+ public static void Main() {
+ Console.WriteLine("test".Replace("\0",
+string.Empty));
+ }
+ }
+}
+
+On Mono/Windows this will yield :
+
+** Message: : usearch_open error: U_ILLEGAL_ARGUMENT_ERROR
+(next is an empty line as the result of the Replace method is null on
+Mono/Windows)
+
+On MS.NET this yields:
+
+test