Added defined(NOS) preprocessor to avoid defining XMALLOC, XFREE, and XREALLOC to non-NOS heap functions.