public override void ReleaseAllocationInfo(byte *baseAddress, long size) { if (Win32MemoryMapNativeMethods.UnmapViewOfFile(baseAddress) == false) { throw new Win32Exception(); } }
private static void UndoMappings(IEnumerable <PagerState.AllocationInfo> newAllocationInfos) { foreach (var newAllocationInfo in newAllocationInfos) { Win32MemoryMapNativeMethods.UnmapViewOfFile(newAllocationInfo.BaseAddress); } }
public override void ReleaseAllocationInfo(byte *baseAddress, long size) { if (Win32MemoryMapNativeMethods.UnmapViewOfFile(baseAddress) == false) { throw new Win32Exception(Marshal.GetLastWin32Error(), "Failed to UnMapView of file " + FileName); } NativeMemory.UnregisterFileMapping(_fileInfo.FullName, new IntPtr(baseAddress), size); }
public override void ReleaseAllocationInfo(byte *baseAddress, long size) { if (Win32MemoryMapNativeMethods.UnmapViewOfFile(baseAddress) == false) { throw new Win32Exception(); } NativeMemory.UnregisterFileMapping(_fileInfo.FullName, new IntPtr(baseAddress), size); }