- Home /
Marshal.PtrToStructure in iPhone makes error.
Hi!
I have been working with it for over 3 days.
[StructLayout(LayoutKind.Sequential, Pack = 1)] public class Header { public ushort psize; public ushort cmd; public uint sequenceNum; }
IntPtr p = GetDataFromNative(); Header h = new Header();
h = (Header)Marshal.PtrToStructure(p, typeof(Header));
Marshal.PtrToStructure makes following error. Unhandled Exception: System.ExecutionEngineException: Attempting to JIT compile method '(wrapper unknown) Header:StructureToPtr (object,intptr,bool)' while running with --aot-only.)
How can I solve that problem ? Please Help me...
Best Regards, Adam.
Your answer
Follow this Question
Related Questions
Is there possible to use Objective-C code inside C unity plugin? 0 Answers
Linking Native toolkit 1 Answer
Objective-C and C code in unity plugin 1 Answer
A node in a childnode? 1 Answer
Calling UnitySendMessage requires which library on iOS? 2 Answers