Removed Malloc as a #define.   Added Malloc as a method to both ArrayTempate and IndexTree.
Preemptively converted Cimage*s to Ptr<CImage> in SupportLib.