MapCallerPtr

Other versions of this page are also available for the following:
Windows Mobile Not SupportedWindows Embedded CE Supported
8/28/2008

This function checks whether a region of memory is valid with respect to the caller process.

Note   This function is no longer supported as of CE 6.0.


LPVOID MapCallerPtr(
  LPVOID ptr,
  DWORD dwLen
);

ptr

[in] Pointer to the region of memory.

dwLen

[in] Length, in bytes, of the region of memory.

The mapped version of ptr indicates that the region is valid. NULL indicates failure.

MapCallerPtr is generally used in device driver I/O controls to validate the pointer parameters passed by the caller process. Because device drivers usually run with higher privileges and have access to more memory, if you do not call this function to validate the parameters, it could overwrite a process's memory. It could also overwrite the kernel memory if called from a malicious application.

Headerpkfuncs.h
Librarycoredll.lib
Windows Embedded CEWindows CE .NET 4.0 and later

Community Additions

Show: