Validity Checks

The Kernel can be configured to check that programs meet various pre-conditions before they call kernel-side functions.

These checks are important, as incorrect calls can cause damage to the integrity of the kernel and the whole system.

The code that checks the conditions can be conditionally compiled in for debug builds and test ROMs of Symbian platform. For production devices, this code can be compiled out so that it does not affect performance.

To include the validity checking code, define one or both of these macros:

  • __KERNEL_APIS_CONTEXT_CHECKS_WARNING__

  • __KERNEL_APIS_CONTEXT_CHECKS_FAULT__

in the file ...\e32\kernel\kern_int.mmh.

Before building production code, these two macros must be removed. In practice, they will be marked as a comment rather than being completely deleted from the file.

Related concepts
Kernel API Validity Checks