[Mono-bugs] [Bug 80426][Wis] Changed - Problem with interop and wide strings (narrow strings are ok)

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Jan 2 22:59:16 EST 2007

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 jonpryor at vt.edu.


--- shadow/80426	2007-01-02 11:34:43.000000000 -0500
+++ shadow/80426.tmp.19047	2007-01-02 22:59:16.000000000 -0500
@@ -1,14 +1,14 @@
 Bug#: 80426
 Product: Mono: Class Libraries
 Version: 1.2
+OS: unknown
 OS Details: RHEL kernel 2.6.9-42 on i686
 Status: NEW   
+Severity: Unknown
 Priority: Wishlist
 Component: System
 AssignedTo: mono-bugs at ximian.com                            
 ReportedBy: Dan.Maser at inin.com               
 QAContact: mono-bugs at ximian.com
 TargetMilestone: ---
@@ -57,6 +57,21 @@
 How often does this happen? 
   Each time
 Additional Information:
+------- Additional Comments From jonpryor at vt.edu  2007-01-02 22:59 -------
+Are you sure you're always getting narrow strings?
+The last time I looked into this behavior, your scenario wouldn't work
+because, under Unix, sizeof(wchar_t) == sizeof(int) == 4, while Mono
+would pass Win32 WCHAR strings (sizeof(WCHAR) == 2).  So wchar_t*
+would still be marshaled "wrong," as strings would marshal as UTF-16
+(WCHAR*) instead of UTF-32 (wchar_t*).
+This was by design.
+Has this changed?  Are you *sure* you're getting
+0x48,0x65,0x6c,0x6c,0x6f,0x00 and not 0x0048 0x0065 0x006c 0x006c
+0x006f 0x0000?

More information about the mono-bugs mailing list