VirtualFree( addr, 0, MEM_RELEASE );
}
+/***********************************************************************
+ * MmIsAddressValid (NTOSKRNL.EXE.@)
+ *
+ * Check if the process can access the virtual address without a pagefault
+ *
+ * PARAMS
+ * VirtualAddress [I] Address to check
+ *
+ * RETURNS
+ * Failure: FALSE
+ * Success: TRUE (Accessing the Address works without a Pagefault)
+ *
+ */
+BOOLEAN WINAPI MmIsAddressValid(PVOID VirtualAddress)
+{
+ TRACE("(%p)\n", VirtualAddress);
+ return !IsBadWritePtr(VirtualAddress, 1);
+}
+
/***********************************************************************
* MmPageEntireDriver (NTOSKRNL.EXE.@)
*/
@ stub MmGetVirtualForPhysical
@ stub MmGrowKernelStack
@ stub MmHighestUserAddress
-@ stub MmIsAddressValid
+@ stdcall MmIsAddressValid(ptr)
@ stub MmIsDriverVerifying
@ stub MmIsNonPagedSystemAddressValid
@ stub MmIsRecursiveIoFault