.Net Core项目中kernel32.dll的CopyMemory函数报错解决方案
[DllImport("kernel32.dll", SetLastError = false)]
private static extern void CopyMemory(IntPtr destination, IntPtr source, uint length);
System.EntryPointNotFoundException:“Unable to find an entry point named 'CopyMemory' in DLL 'kernel32.dll'.”
[DllImport("kernel32.dll", EntryPoint = "RtlMoveMemory", SetLastError = false)]
private static extern void CopyMemory(IntPtr destination, IntPtr source, uint length);
参考链接:https://github.com/dotnet/runtime/issues/12496