IMAGE_DOS_HEADER (Structures)

Announcements and discussion for PInvoke

Moderators: Luke Jefferson, Robert

IMAGE_DOS_HEADER (Structures)

Postby Sam Hobbs » Thu Feb 28, 2013 5:56 pm

I think the previous definition of the IMAGE_DOS_HEADER Structure will not work. I added an "unsafe" C# definition. The other one will not work because it uses "char" and since the data is ASCII the char will use 16 bytes. The unsafe version uses "fixed" which allows use when references are not allowed.

I do not know how to add a note explaining that the unsafe version will work in situations where the other one will not.
Sam Hobbs
 
Posts: 2
Joined: Tue Apr 13, 2010 3:33 am
Location: California

Postby Brian Donahue » Mon Mar 04, 2013 11:00 am

I suppose the best thing to do would be to put this under "Notes" for the function...
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am


Return to PInvoke.Net

Who is online

Users browsing this forum: No registered users and 0 guests