[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pnet-developers] [Bug #3668] Custom marshalers do not work properly

From: nobody
Subject: [Pnet-developers] [Bug #3668] Custom marshalers do not work properly
Date: Sun, 01 Jun 2003 15:45:54 -0400

=================== BUG #3668: LATEST MODIFICATIONS ==================

Changes by: Gopal.V <address@hidden>
Date: Mon 06/02/03 at 01:15 (Asia/Calcutta)

            What     | Removed                   | Added
          Resolution | None                      | Fixed
              Status | Open                      | Closed

------------------ Additional Follow-up Comments ----------------------------
It's fixed now or has been for a few days

=================== BUG #3668: FULL BUG SNAPSHOT ===================

Submitted by: mathpup                 Project: DotGNU Portable.NET          
Submitted on: Sun 05/18/03 at 11:27
Category:  None                       Severity:  5 - Major                  
Bug Group:  None                      Resolution:  Fixed                    
Assigned to:  None                    Status:  Closed                       

Summary:  Custom marshalers do not work properly

Original Submission:  The bug report has more information than I would usually 
give because the topic is less likely to be familiar.

The documentation on implementing custom marshalers is quite vague, and further 
information is very scarce. However, I able to put together a trivial example 
of a custom marshaler to see if I could get it working.

The sample marshaler takes an Ansi C-string from unmanaged code and turns it 
into a C# string, placing asterisks around the string to differentiate this 
from the default marshaling.

The program creates a C# delegate that is indirectly invoked from unmanaged 
code, to test the marshaling.

With Rotor, I get the output "s = *ABC*".
With ilrun, I get "s = *v

This might be bug in Marshal.PtrToStringAnsi() or in custom marshaling 
component of the runtime.

I'm attaching a test case.

1. Build a shared lib of invoke.cpp: cpp -shared -o invoke.cpp
2. Build the C# test: cscc -o MyMarshal.exe MyMarshal.cs
3. Run the program: ilrun MyMarshal.exe

Follow-up Comments

Date: Mon 06/02/03 at 01:15         By: t3rmin4t0r
It's fixed now or has been for a few days

CC list is empty

File Attachments

Date: Sun 05/18/03 at 11:27  Name: invoke.cpp  Size: 0KB   By: mathpup
Test case;bug_id=3668&amp;bug_file_id=458

For detailed info, follow this link:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]