[Mono-bugs] [Bug 78722][Nor] Changed - UnmanagedType.ByValTStr should be Unicode when the structure is Unicode

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Mon Jan 1 22:58:52 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 miguel at ximian.com.

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

--- shadow/78722	2006-06-28 13:48:06.000000000 -0400
+++ shadow/78722.tmp.30322	2007-01-01 22:58:52.000000000 -0500
@@ -41,6 +41,17 @@
 ByValTStrTest.cs
 
 
 ------- Additional Comments From vargaz at gmail.com  2006-06-28 13:48 -------
 Fixed in SVN.
 
+
+------- Additional Comments From miguel at ximian.com  2007-01-01 22:58 -------
+btw, this test case is broken:
+
+The test from 78722 is broken though, because it is writing 2 bytes
+past the allocated size:
+
+pDataStruct = Marshal.AllocHGlobal(size + 2);
+Marshal.WriteInt32(pDataStruct, size, (int)'X');
+
+Which leads to a crash later on.


More information about the mono-bugs mailing list