Free() public static method

Releases a region of memory within the virtual address space of a specified process.
public static Free ( SafeMemoryHandle processHandle, IntPtr address ) : void
processHandle Binarysharp.MemoryManagement.Native.SafeMemoryHandle A handle to a process.
address System.IntPtr A pointer to the starting address of the region of memory to be freed.
return void
Example #1
0
 /// <summary>
 /// Releases the memory used by the region.
 /// </summary>
 public void Release()
 {
     // Release the memory
     MemoryCore.Free(MemorySharp.Handle, BaseAddress);
     // Remove the pointer
     BaseAddress = IntPtr.Zero;
 }