[Mono-bugs] [Bug 469217] Pointers can not reference marshaled structures.

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Oct 26 20:34:39 EDT 2009


User eugeny.grishul at gmail.com added comment

Eugeny Grishul <eugeny.grishul at gmail.com> changed:

           What    |Removed                     |Added
             Status|RESOLVED                    |REOPENED
            Version|2.2.x                       |2.4.x
         Resolution|FIXED                       |

--- Comment #4 from Eugeny Grishul <eugeny.grishul at gmail.com>  2009-10-26 18:34:35 MDT ---
I tried following testcase on Mono and again I have this bug.

using System;
using System.Runtime;
using System.Runtime.InteropServices;

namespace MonoTest
    unsafe class Program
        static void Main( string[] args )
            printf( ( SomeStruct* ) Marshal.StringToHGlobalAnsi( "this text
appears only in MS.NET VES!\r\n" ).ToPointer() );

        unsafe struct SomeStruct
            public System.IntPtr _ptr;

        [DllImport( "msvcrt.dll" )]
        static extern void printf( SomeStruct* arr );

Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.

More information about the mono-bugs mailing list