Error!
Success!

Marshal opaque structs as IntPtr instead of Byte[]

0
kicks

Marshal opaque structs as IntPtr instead of Byte[]  (Unpublished)

If you have an opaque native structure that you want to pass through managed code, consider using IntPtr, not Byte[], in your marshalling signatures. Opaque means that you don't care about the contents of the buffer. For example, if in C#, you pinvoke to get an opaque native structure that you then hand to some other native API, the pinvoke definitions should use IntPtr instead of Byte[].


Kicked By:
Drop Kicked By: