コード例 #1
0
ファイル: Operations.cs プロジェクト: nnikos123/Sichem
 public static void MemMove(void *a, void *b, long size)
 {
     using (var temp = new PinnedArray <byte>(size))
     {
         Memcpy(temp.Ptr, b, size);
         Memcpy(a, temp.Ptr, size);
     }
 }
コード例 #2
0
ファイル: Operations.cs プロジェクト: nnikos123/Sichem
        public static void *Malloc(long size)
        {
            var result = new PinnedArray <byte>(size);

            _pointers[(long)result.Ptr] = result;

            return(result.Ptr);
        }